Forum Moderators: not2easy

Message Too Old, No Replies

Multiple css stylesheets

Multiple css stylesheets

         

dunhill

4:44 am on Jul 3, 2006 (gmt 0)

10+ Year Member



Hello All, I need your help PLEASE.

I have used a css stylesheet to define my website pages, this works 100%.

I then went and found a menu and a feeback/footer script, both of these have their own css stylesheet.

The problem I am having is that the stylesheets seem to be overwriting each others properties.

My Example is:

MYPAGES.php contains the following:
Include HEADER.php
BLA BLA BLA
BLA BLA BLA
Include FOOTER.php

So in the above scenario it appears that the FOOTER.php stylesheet is being used on the entire page - MYPAGES.php.

Is there a way to use the css stylesheet only in the page that is calling it. So in my example I want HEADER.php to call its own, FOOTER.php its own and MYPAGES.php its owns.

Thank you.

jonrichd

2:52 pm on Jul 3, 2006 (gmt 0)

10+ Year Member



Why not create separate <DIV>s for the header and footer, and then redefine the styles in the header and footer stylesheets so that they only apply to the appropriate division.

e.g.
#header p (header style here}
#footer p {footer style here}

Anything not defined in the header or footer stylesheets would fall through from your main stylesheet.