1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How to make a universal header

Discussion in 'PHP' started by fly4food84, Apr 21, 2008.

  1. #1
    I have a 10 page website and use the same header for all the pages. Every so often I update my keywords and I have to edit each page individually. I want to place all my meta data in one file so that is all I have to update for it to take effect on all pages.

    How would I do this?

    Thanks
     
    fly4food84, Apr 21, 2008 IP
  2. ToddMicheau

    ToddMicheau Active Member

    Messages:
    183
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    58
    #2
    There are quite a number of ways to do this, it depends on how clean you want it and what language you are using.
    I would suggest you check out this link: http://webdesign.about.com/od/ssi/a/aa052002a.htm
    It details ways to include other files into your pages, using a number of strategy's from JS to SSI.

    Just pick a way that suits your framework then create a file with the standard header, include that using the method and there you are.
     
    ToddMicheau, Apr 21, 2008 IP
  3. fly4food84

    fly4food84 Peon

    Messages:
    118
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Thanks for the help!
     
    fly4food84, Apr 21, 2008 IP