Forgive me if this seems a little dumb, but I want to include a Top Section List with Javascript and although I've read the Advanced Users Guide I'm a bit lost as to how to implement this. Basically I want simple text links to the Top Sections in the Extended Info pages. Can anyone help me with this please?
Announcement
Collapse
No announcement yet.
Trying to generate Javascipt Menu
Collapse
X
-
I've tried this but I am having difficulty making the menu look quite different in two seperate places. ie, the main Top Level menu on the main pages is vertical and bold, the menu on the Extended info pages will be more subtle in a muted horizontal format. Can I use the same variable for this?
Comment
-
You can't easily use the same thing to do 2 completely different looks, that's not catered for because on most occasions people will want standard familiar nav on all pages. I think you may be forced to go down using a Block on the entiresectionlist and limiting it to sectionlevel 1 via a blockif and then styling that yourself with html and css to get the look you are after.
The below code should be a good starting point for you.
Code:<ul><actinic:block type="EntireSectionList" ><actinic:block if="%3cactinic%3avariable%20name%3d%22SectionLevel%22%20%2f%3e%20%3d%3d%201" ><li><a href="<actinic:variable name="SectionPageName"/>"><actinic:variable name='SectionName'/></a></li></actinic:block></actinic:block></ul>
Comment
-
This is a good start, thanks. Only thing is trying to reformat seems ineffective both at CSS level and simply specifying font size and style. Nothing seems to change it. I am doing this by Editing Appearance of the SectionName variable. Is this correct?
Curiously, why do you not think Javascript is the way to go?
Comment
-
You need to use html and css to style it, don't touch the edit appearance part, that's a no-no area to do it in. Google is probably your best bet to learn that part, do some horizontal nav tutorials. The code i provided you with creates a standard <ul> as per what all tutorials use.
You have no need for Javascript to do what you want, therefore pointless involving it. In nav terms, you cannot get a simpler requirement than what you have and actinic does it all as standard for you, if you know how to style it - i think this is the crux to be honest, you clearly don't from the way you have started to do the styling. Do the tutorials and you will see then, it's really simple once you get what you are doing.
Comment
Comment