I just learned that you can even use PHP on style sheets. Can anyone here tell me how to set it up?
Add this to your .htaccess file: <Files ~ "\.css$"> ForceType application/x-httpd-php </Files>
Add this to the top of your CSS file: <?
Then you can use it to do all sorts of stuff:
---
<?
header("Content-Type: text/css");
include("../inc/colours.inc");
?>
body {
background-color: #<?=$col[1]?>;
color: #<?=$col[1]?>;
}<? if(something) { ?>
p {
font-size: 110%;
}
<? } ?>/*etc etc*/ ---
Justin French
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

