PDA

View Full Version : PHP and CSS


drums
09-29-2002, 10:45 PM
Just started trying to move my pages to PHP and have run into the problem with my css not showing. I am fiddling with FastTemplate and am just trying to take one thing at a time. Everything seems to be working except for my css.
Where does the call go for my external style sheet?
It's in the header.tpl. The images show but not css.

Can anyone help?
Thanks in advance!

Alekz
09-30-2002, 09:13 AM
Hi,
You can not call SCC from PHP... It's a client side technique... Just include a refernce to Your CSS file in the head as usual...

Alex

c q
09-30-2002, 11:20 AM
just some code you might wanna consider
<?php
include(mystylesheet.inc);
?>

but remember to have your mystylesheet.inc in this format...

<style>
body {color:black; margin:0;}
p {color:navy; .....
//or whatever else u put into your stylesheet...
</style>

drums
09-30-2002, 03:25 PM
Thanks!
I figured it out myself through trial and error and although I didn't use an include, I used a .TPL runnig from FastTemplate.