javascript:history.go(-1) in template being rewritten with WCMS path
I'm trying to include an href with "javascript:history.go(-1)" as the path in a template, but every time i go to publish it, wcms rewrites it with a wcms relative path. how can i include this javascript in my template?
Discussions are closed to public comments.
If you need help with Cascade CMS please
start a new discussion.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
1 Posted by Ryan Griffith on 10 Aug, 2012 08:07 PM
Hi fuelishways,
This is a known defect in Cascade that causes links containing javascript: to be incorrectly rewritten during Template submission. Feel free to track the status of this issue using the link I have provided to see if it has been resolved in a future version of Cascade.
In the meantime, there are a few workarounds that you could try:
<a href="#" onclick="history.go(-1)">Go back</a>
Please let us know if you have any questions.
Thanks.
2 Posted by fuelishways on 10 Aug, 2012 08:13 PM
The onclick method doesn't seem to work in chrome. It also doesn't work in iOS.
3 Posted by Ryan Griffith on 13 Aug, 2012 12:48 PM
It looks like Chrome and Safari (iOS) are a little more finicky. Let's try the following:
Please let me know if this works out for you.
Thanks.
fuelishways closed this discussion on 21 Aug, 2012 05:38 AM.