SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Member
    Join Date
    May 2013
    Posts
    6
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Creating a CSS Menu on a separate page

    I have just updated my website <snip /> to include a CSS menu, with a separate file containing the CSS formatting etc. The next stage is to move the menu and heading into a separate file so that if I add a page, I only need to change the menu once.

    The test page is /Template.html, which references /menu.html . I have followed guidance on this forum as regards the language. I have tried renaming the menu.html file to be .php (changing the code in main page), but this didn't work either.

    As you can see from my history here, I am a novice and amateur with no real background in programming or web-design, so any help would be appreciated.
    Last edited by cpradio; May 24, 2013 at 07:13. Reason: Removed the link

  2. #2
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,297
    Mentioned
    460 Post(s)
    Tagged
    8 Thread(s)
    Hi denis8991,

    A good way to do this is with "PHP includes", which are very easy to do. Here's a rundown of it that I put together a while back: http://pageaffairs.com/notebook/enha...h-php-includes

  3. #3
    SitePoint Member
    Join Date
    May 2013
    Posts
    6
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Great - followed the instructions, and it worked with the test page as a .php file instead of .html. I will now follow the instructions on how to make it work with the existing html pages using a .htaccess file.

    Thanks for your help


Bookmarks

Posting Permissions

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