Menu and design elements on every page

Discussion in 'HTML' started by Steven LaPha Jr., Apr 3, 2004.

  1. I was wondering if there was an easy way to seperate out the menu and some
    design elements (logos in CSS boxes) and the like so they can be used on
    every page. Instead of writing the code on every single page.

    What I was thinking is along the way of including/importing. Like include a
    simple HTML file with each page, that way I just have to update 1 page to
    update all the menus and anything else that remains consistant on each page.

    I know it's possible and have seen the code for it, but now here's the
    question, how well does it work with MOST browsers (talking IE, Netscape,
    Opera). Also since it would hold critical parts of the webpage it would have
    to load fast as well.

    Not looking for any PHP, CGI, ASP or whatever, just asking if the simple
    solution works, or if there is something else equal to it. I just have a
    basic hosting so nothing fancy.

    Just wondeirng how everyone else does it.

    Thanks
     
    Steven LaPha Jr., Apr 3, 2004
    #1
    1. Advertising

  2. Steven LaPha Jr.

    Spartanicus Guest

    "Steven LaPha Jr." <> wrote:

    >I was wondering if there was an easy way to seperate out the menu and some
    >design elements (logos in CSS boxes) and the like so they can be used on
    >every page. Instead of writing the code on every single page.


    Server side is the only proper way to do this.

    --
    Spartanicus
     
    Spartanicus, Apr 3, 2004
    #2
    1. Advertising

  3. Steven LaPha Jr.

    brucie Guest

    in post: <news:eDtbc.398104$>
    "Steven LaPha Jr." <> said:

    > I was wondering if there was an easy way to seperate out the menu and some
    > design elements (logos in CSS boxes) and the like so they can be used on
    > every page. Instead of writing the code on every single page.


    http://allmyfaqs.com/faq.pl?Include_one_file_in_another



    --
    b r u c i e
     
    brucie, Apr 3, 2004
    #3
  4. Steven LaPha Jr.

    SpaceGirl Guest

    "brucie" <> wrote in message
    news:c4lref$2kph4t$-berlin.de...
    > in post: <news:eDtbc.398104$>
    > "Steven LaPha Jr." <> said:
    >
    > > I was wondering if there was an easy way to seperate out the menu and

    some
    > > design elements (logos in CSS boxes) and the like so they can be used on
    > > every page. Instead of writing the code on every single page.

    >
    > http://allmyfaqs.com/faq.pl?Include_one_file_in_another
    >
    >
    >
    > --
    > b r u c i e


    Be careful with that FAQ... with blanket statements like "JavaScript was
    another suggested option, but JavaScript is unavailable on about 15% of
    browsers and, like SSI, inserts computation time into every page-fetch" it
    is seriously misleading.
     
    SpaceGirl, Apr 3, 2004
    #4
  5. Steven LaPha Jr.

    brucie Guest

    in post: <news:c4m77l$2kq9le$-berlin.de>
    "SpaceGirl" <> said:

    >> http://allmyfaqs.com/faq.pl?Include_one_file_in_another


    > Be careful with that FAQ... with blanket statements like "JavaScript was
    > another suggested option, but JavaScript is unavailable on about 15% of
    > browsers and, like SSI, inserts computation time into every page-fetch" it
    > is seriously misleading.


    apart from the 15% which is debatable the quote is correct. if you think
    it should be changed then change it.

    --
    b r u c i e
     
    brucie, Apr 3, 2004
    #5
  6. Steven LaPha Jr.

    Rob McAninch Guest

    brucie <news:c4lref$2kph4t$-berlin.de>:

    > in post:
    > <news:eDtbc.398104$> "Steven
    > LaPha Jr." <> said:
    >
    >> I was wondering if there was an easy way to seperate out the
    >> menu and some design elements (logos in CSS boxes) and the
    >> like so they can be used on every page. Instead of writing
    >> the code on every single page.

    >
    > http://allmyfaqs.com/faq.pl?Include_one_file_in_another


    I'd recommend either preprocessing or SSI. The basic inclusion,
    via SSI, of a simple text file adds very little to the response
    time. It might become an issue on a very busy site but I doubt
    that (since a busy site is probably using other server side
    technologies and database accesses anyhow.)


    --
    Rob - http://rock13.com/
    Web Stuff: http://rock13.com/webhelp/
     
    Rob McAninch, Apr 3, 2004
    #6
  7. In article <eDtbc.398104$>, Steven
    LaPha Jr. <> wrote:

    > I was wondering if there was an easy way to seperate out the menu and some
    > design elements (logos in CSS boxes) and the like so they can be used on
    > every page. Instead of writing the code on every single page.
    >
    > What I was thinking is along the way of including/importing. Like include a
    > simple HTML file with each page, that way I just have to update 1 page to
    > update all the menus and anything else that remains consistant on each page.
    >
    > I know it's possible and have seen the code for it, but now here's the
    > question, how well does it work with MOST browsers (talking IE, Netscape,
    > Opera). Also since it would hold critical parts of the webpage it would have
    > to load fast as well.
    >
    > Not looking for any PHP, CGI, ASP or whatever, just asking if the simple
    > solution works, or if there is something else equal to it. I just have a
    > basic hosting so nothing fancy.
    >
    > Just wondeirng how everyone else does it.
    >
    > Thanks
    >
    >

    You can see a javascript method at my site. Since I don't have any
    server side options available without extra cost this is the method I
    chose.

    There is a common menu that is always visible on the home page and can
    be made to appear or disappear on other pages. The heading is unique on
    the home page and is dynamically generated on other pages using the
    page title.

    --
    Dennis M. Marks
    http://www.dcs-chico.com/~denmarks/
    Replace domain.invalid with dcsi.net


    -----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
    http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
    -----== Over 100,000 Newsgroups - 19 Different Servers! =-----
     
    Dennis M. Marks, Apr 3, 2004
    #7
  8. Steven LaPha Jr.

    Ramen Junkie Guest

    "Steven LaPha Jr." <> wrote in message
    news:eDtbc.398104$...
    > I was wondering if there was an easy way to seperate out the menu and some
    > design elements (logos in CSS boxes) and the like so they can be used on
    > every page. Instead of writing the code on every single page.
    >
    > What I was thinking is along the way of including/importing. Like include

    a
    > simple HTML file with each page, that way I just have to update 1 page to
    > update all the menus and anything else that remains consistant on each

    page.
    >
    > I know it's possible and have seen the code for it, but now here's the
    > question, how well does it work with MOST browsers (talking IE, Netscape,
    > Opera). Also since it would hold critical parts of the webpage it would

    have
    > to load fast as well.
    >
    > Not looking for any PHP, CGI, ASP or whatever, just asking if the simple
    > solution works, or if there is something else equal to it. I just have a
    > basic hosting so nothing fancy.
    >
    > Just wondeirng how everyone else does it.



    Well here's a slightly different possible solution that could work depending
    on how much the logos and menu need to be updated. You could always just
    create a blank "template" file and edit that as needed. My page (when it's
    online) has an upper logo and a menu on one side and only the content in the
    center changes. I've got a template file on my computer that has the logo
    and menu but nothing in the content area. When I need to update I just copy
    the template file, rename the copy, then fill in the content. This way I
    don't have to code the menu and title every time. Not to mention it means
    the code for all the pages is extremely consistent. Since most of the
    content is text articles it also means I can type them up in Word or
    something where I have a spell checker, then paste the text into to the
    template then quickly paste in line breaks where necessary.

    That solution may have nothing to do with what you're trying to do though I
    suppose.
    --
    Ramen Junkie

    http://www.lameazoid.com is offline at the moment.
     
    Ramen Junkie, Apr 3, 2004
    #8
  9. Steven LaPha Jr.

    Mitja Guest

    "Steven LaPha Jr." <> wrote in message
    news:eDtbc.398104$...
    > I was wondering if there was an easy way to seperate out the menu and some
    > design elements (logos in CSS boxes) and the like so they can be used on
    > every page. Instead of writing the code on every single page.
    >
    > What I was thinking is along the way of including/importing.
    > .......


    I've skimmed through other's answers; I think most options have already been
    mentioned. If you don't change the content of your pages all that often,
    there's another possibility. Write a short program (or make use of a
    commercial one) that can process HTML-like files with include directives and
    then put its output online. It's very much like server-side scripting, but
    if you don't have the possibility of the latter, that's another way to go.
     
    Mitja, Apr 3, 2004
    #9
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. James Doran
    Replies:
    2
    Views:
    609
    James Doran
    Jun 15, 2004
  2. James Doran
    Replies:
    0
    Views:
    379
    James Doran
    Jun 18, 2004
  3. dollar

    web menu in every page

    dollar, May 6, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    365
    Lucas Tam
    May 6, 2005
  4. Matt White

    Same Menu On Every Page

    Matt White, Aug 10, 2007, in forum: HTML
    Replies:
    8
    Views:
    1,017
    Bernhard Sturm
    Aug 11, 2007
  5. =?Utf-8?B?SXJ3YW5zeWFo?=
    Replies:
    4
    Views:
    2,463
    =?Utf-8?B?SXJ3YW5zeWFo?=
    Oct 30, 2007
Loading...

Share This Page