Announcement

Collapse
No announcement yet.

disabling top level links within nortree

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    disabling top level links within nortree

    hi everyone,
    I have used a nortree menu system on my site to allow easy navigation for users however a probelm has arisen that I had not considered. Ideally I want users to be taken directly to my products however I realise that the menu is created from each html page that has been created on my site.

    Does anybody know a way to disable the top level links of a nortree menu so that the user can only click on the product links.

    please find below a link to the test site to further explain my problem.

    http://trials.actinic.com/trials/trial2991

    Any help would be appreciated.
    Regards.

    Lee Jackson
    Creative Director

    Centurius Design & Marketing
    Centurius Website
    Portfolio of Work

    #2
    I wasn't going to investigate this as I'm feeling lazy but you'd done such a nice integration of the menu into your site that I woke up a bit.

    Try this:-
    Code:
    in notree_menu_create.js in your Site1 folder, look for the line:-
    
       eval('Menu' + base + i + '=new Array("' + SName
    
    
    ADD the following line above it.
    
      if ( thislevel == 1 ) LinkURL = ''; // disable link on top level
    Best to copy and paste from the text above as that's a pair of single quotes there and you might type the wrong thing in if you eyeball it.

    I've not tested this but it's easy to undo if it's wrong.

    A side effect is that you'll lose your link to Audio Accessories as they have no sub-sections, just products. I'd create some sub-sections and move all the products there if I was you.

    Norman
    Norman - www.drillpine.biz
    Edinburgh, U K / Bitez, Turkey

    Comment


      #3
      Error caused by code

      Norman,
      I tried what you said but the code causes an error in building the menu. Have removed the line and menu now back to normal. Thanks for your suggestion.
      Regards.

      Lee Jackson
      Creative Director

      Centurius Design & Marketing
      Centurius Website
      Portfolio of Work

      Comment


        #4
        Told you I hadn't tested it. I missed some capitalisation. Sorry. Here's it again (and tested OK).


        Code:
        in nrotree_menu_create.js in your Site1 folder, look for the line:-
        
           eval('Menu' + base + i + '=new Array("' + SName
        
        
        ADD the following line above it.
        
          if ( ThisLevel == 1 ) LinkURL = ''; // disable link on top level
        Norman
        Norman - www.drillpine.biz
        Edinburgh, U K / Bitez, Turkey

        Comment


          #5
          Norman,
          if I ever get the chance to meet you then remind me to buy you a very large shot or pint of whatever you want. =)

          Thankyou very much for your help!

          Lee
          Regards.

          Lee Jackson
          Creative Director

          Centurius Design & Marketing
          Centurius Website
          Portfolio of Work

          Comment


            #6
            Glad it worked. I'm at approx 36.40N, 27.34E at the moment so you'll need to be a good swimmer.

            Norman
            Norman - www.drillpine.biz
            Edinburgh, U K / Bitez, Turkey

            Comment

            Working...
            X