www.webdeveloper.com
Results 1 to 4 of 4

Thread: External JS Menu Help

  1. #1
    Join Date
    Jan 2009
    Posts
    9

    Question External JS Menu Help

    Hey all,

    I am converting all my pages to CSS. One thing I want to do is have a drop-down menu.

    I have looked all over and tried to find code for this [I'm not the world's most advanced programmer] because I want to have the menu run externally [so I don't have to edit every page!]

    The way I used to do this was with JS but is that an out-of-date approach? All I want is a drop-down menu with an external reference file with the actual menu bits in it. If I can then format it with css, all the more awesome.

    I apologize if this is vague or very newbie-ish but the search engines are failing me here, or I need to adapt what might be out-of-date knowledge in my head. I would GREATLY appreciate any advice about how to do this - if JS is the right approach, and if so, do you know of any [free] code I could use? I can customize it from there.

    Thank you so much in advance! I appreciate it.

  2. #2
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    21,654
    Use includes, SSI or PHP include

  3. #3
    Join Date
    Jan 2009
    Posts
    9
    I can get the php to work [thank you] but now I'm have a huge amount of difficulty no matter what I try trying to parse the html. Meaning, I want to keep the index page at least an html page [and not a .php page]. I use godaddy and am trying to work out how to get the .htaccess thing to work, found some links but nothing I try is working.

    My concern is that my site is a .org site. If I switch to an index page that is .php, will those that linked to the original .org site now have broken links?

    Apologies if this is OT but I guess my initial enquiry is broadening. Sorry for any noobishness but I am trying and have read a ton but am still confused.

  4. #4
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    21,654
    Add this to the .htaccess file
    Code:
    AddHandler x-httpd-php .php .htm html

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles