history back button
-
Re: history back button
hello, I want to add a history back link. i don’t know any js, so this old post and what i found in the documentation for "binding click events" is not helping me. can you guide me trough the steps? -
hi
can u try this
put this in lay options -> custom css & html -> custom <head> content:<script> jQuery(document).on("click", ".back", function(event) { event.preventDefault(); event.stopPropagation(); history.back(); }); </script> <style> .back{ cursor: pointer; } </style>now in the gridder edit a text, open the code editor in the text and then on any html element add the class "back"
so for example:
<p class="back">hello</p>or right click an element in the gridder, choose set html class and id
and as a class add
back
-
hi
can u try this
put this in lay options -> custom css & html -> custom <head> content:<script> jQuery(document).on("click", ".back", function(event) { event.preventDefault(); event.stopPropagation(); history.back(); }); </script> <style> .back{ cursor: pointer; } </style>now in the gridder edit a text, open the code editor in the text and then on any html element add the class "back"
so for example:
<p class="back">hello</p>or right click an element in the gridder, choose set html class and id
and as a class add
back
@arminunruh works perfectly, thanks a lot!
-
Thank you @arminunruh this is just what I was looking for!