We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 18367
    • 834 Posts
    I’m having trouble making evo return to a named anchor.

    See here

    http://makethemclick.com.au/online-marketing/smarter-marketing-services

    The side menu works ok and I can see the anchors when I scroll over the side menu

    but if I try and use for example http://makethemclick.com.au/online-marketing/smarter-marketing-services#3

    nothing happens.

    Can anyone tell me where I’m going wrong?

    Thanks
      Content Creator and Copywriter
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      Your javascript doesn’t know that you’ve "tabbed" to the specified tab, since the actual link on the left is what triggers the tabbing function.
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 36404
        • 307 Posts
        hi,

        i think you’ve not exactly understood how your tab js and anchors work...

        your #number should go to an anchor if it found a something id="number" in the source code, which is not the case (fortunately as would not be a valid id...)

        your tab system works using arrays, you have n links and n tab, js simply displays the n tab when clicking on the n link, (#n should even not be necessary here if your links and tab are in the same ordre in the source code)

        if you want your page to work with urls you will have to add
        - either a listener in js that displays the right tab and highlights the right link depending on the index found after the #
        - or a php script that does the same thing server side

        have swing
          réfléchir avant d'agir
          • 18367
          • 834 Posts
          Thanks Susan and VG, I’ll give it a try.

          grin
            Content Creator and Copywriter