Script loading at each page
-
-
Hey!
Try this:<script> Frontend.module("GlobalEvents").on('projectpageshown', function(){ console.log("hello!"); }); </script>The name i picked is a bit misleading. Actually this event will trigger on a category-load as well.
-
Theres also another event just for pages and projects:
<script> Frontend.module("GlobalEvents").on('newprojectpagelayoutobj', function(layoutObj){ console.log(layoutObj); }); </script>Here you actually get a JavaScript object "layoutObj" which contains the layout information of the current page / project.
-
@arminunruh Works perfectly ! Thank you ;)
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login