The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Navigation and display content

  • This topic is empty.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • #23241

    Hi all,

    Having spent most of the day trying to get wise I have given up and turn to you for help, feeling very stupid, as I am stuck between the utmost basic and the slightly more advanced. I am guessing I am also stuck in the frames-mindset, but can’t find my way out.

    Over the years I have practised the art of "copy-paste and adapt" to my websites, but this does not lwork particularly well any more, thanks to php. So I realise I need to do some learning on my own, but having scanned all sites I have found for an answer, I am getting tired.

    I have downloaded a nice, simple template containing one global.css and one index.html plus some images. It’s a two column layout. My problem is I can’t even make the template display some mock-up content sitting in a separate file when I click a navigation link. How does that work for XHTML 1.0 Transitional and CSS2?

    Help is strongly appreciated, and please do not refer me to W3 Schools, I have spent some time there learning other neat stuff, but not this.

    Any hints on what to put in my code when the template holds something like:
    <div id="side">
    <div id="menu">
    <li><a href="#">Page four</a></li>
    <li><a href="#">Page five</a></li>

    What do I put in addition / instead for # ?
    In it’s plaines form – I would like the text sitting in the file historie.htm be displayed within the <div id="content">.



    Sorry about being unclear. I will try to rephrase:

    I know how to make links, but the page I link to appear in a separate window. With frames I have pointed the content to the target fram, but I don’t understand how to make the same thing happen using CSS. It probably requires a different way of thinking.

    I have uploaded the template with my small alterations to my server for illustration:
    I would like the content in the link Test to appear in the red square…


    I think I understand what you mean.
    It can’t be done in CSS without frames.
    You need to create a new page using the template for every content page, and link to it.


    What you are looking for, is best handled using Javascript to replace the content on click. Using JQuery Tabs you can create a page that doesn’t require a refresh when a user clicks the navigation.

    If you are using PHP and your issue is that you don’t want each and every page to have the header, menu, and footer code blocks then you would use includes to manage this content in one file and only change the content body from page to page. This way when changing menu items you would edit the header include file and your changes would happen site wide.

    If this is as far as you got… I would suggest finding a developer/designer to assist you with building a web site.

    Michael Plant


    Thanks – you gave me the answers I suspected – there’s no easy way but to spend some more time.

Viewing 5 posts - 1 through 5 (of 5 total)
  • The forum ‘CSS’ is closed to new topics and replies.