Forum Support

 
Advanced Search


[1]

Offline hamiltonpj
Free Member
Posts: 5
Posted on: November 26, 2017, 11:45:33 PM

Greetings,
I am using the Arthur template with Joomla v3.8.2 and I am trying to implement in which when clicking on the Main Menu, it will scroll to a given module; via anchor (ie: #myModule). I have the menu working in that regard of going to the anchor, but does so instantly (which back years ago that is what we wanted, quick and fast...).
The problem I am having is trying to figure out which php file I need to edit to plug in the javascript code to provide the scroll effect.  I attempted with the template index.php, but that did not seem to do the trick.  Assuming of course this can be done, or does this require a core Joomla file to be edited?
Logged

Offline mikek
Free Member
Posts: 28743 WWW

Hello,

You shouldn't be editing any files to do that, you can do that by default in the template. The div just has to start with #s5_ though, it won't interact with any other ID's:

http://www.shape5.com/demo/arthur/index.php/features-mainmenu-47/template-features/menu-scroll-to
Logged

Offline hamiltonpj
Free Member
Posts: 5

Thank you for the reply.
So only works for the positions, but not able to scroll to specific modules.
Reason is I have stacked a few modules into one position due to the allowing for the wide width of the section for a background image.
Example, four modules (top to bottom in order) within Custom_1.
Logged

Offline mikek
Free Member
Posts: 28743 WWW

Hello,

It scrolls to ID's not modules. If you have an ID inside of one of your modules that starts with "s5_" - if it's a custom html module you can add that - then it would scroll to that specific ID/module.
Logged
[1]

Jump to:  


Powered by SMF | SMF © 2013, Simple Machines
Joomla Bridge by JoomlaHacks.com
Page created in 0.017 seconds with 20 queries.
Need some help getting your site up and running? Be sure to check out our tutorials area, post on the forum or hire us
Send Us An Email
Please send us your questions and we will email you back as soon as we can. Product support questions should be posted in our support forums under the Help menu. Our staff will assist you from there.