Hi there!
I find it's troublesome to have a dymanic CSS, i.e.:
Cos it fails to load from the first time, if I reload the page then CSS appears.Code:<link rel="stylesheet" type="text/css" href="css.php" />
| SitePoint Sponsor |





Hi there!
I find it's troublesome to have a dymanic CSS, i.e.:
Cos it fails to load from the first time, if I reload the page then CSS appears.Code:<link rel="stylesheet" type="text/css" href="css.php" />
how does you css.php file know what to output?





It knows, say it has the content.
if it outputs static content, then there is no purpose to using a php file to output css.
if it outputs dynamic content, then there must be some way for it to decide what to output, in which case you did not answer my question.
you are providing us with very little information to try to help you.
im going to make a guess for you:
-it uses cookies or sessions?
Are you sending the correct Content-Type headers?
Before outputting any CSS information in css.php, do:
If that doesn't fix it, then I'm with the crusher of clams - we need more info.PHP Code:header('Content-type: text/css');





In fact the CSS file is a Smarty template which variables can be chaned in the configuration section.
I seem to experience some-kind of FOUC, because if I include the simple CSS file, eveything is ok.
Bookmarks