a Way to Add a New Uniform Link to All Pages on my Site?

Discussion in 'HTML & Website Design' started by rbf738, Feb 12, 2009.

  1. #1
    If I want to add a link to a new aspect of my sitemap, like a contact us section, or maybe even a link to a sitemap if I am just adding one now, how can I add a uniform link to appear in the same position (like as an additional link in my nav bar) without having to go into each individual page and adding it manually that way?
     
    rbf738, Feb 12, 2009 IP
  2. Kerosene

    Kerosene Alpha & Omega™ Staff

    Messages:
    11,366
    Likes Received:
    575
    Best Answers:
    4
    Trophy Points:
    385
    #2
    Use PHP include to "include" a sidebar in each page, then you only need to edit one file (e.g sidebar.php) to change it sitewide.

    include 'sidebar.php';
    PHP:
    http://www.php.net/include/
     
    Kerosene, Feb 12, 2009 IP
  3. wd_2k6

    wd_2k6 Peon

    Messages:
    1,740
    Likes Received:
    54
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Yep use includes for headers sidebars footers and navigation to avoid these time-consuming problems in the future.
     
    wd_2k6, Feb 12, 2009 IP