Posted by:
jmcdonnell
(---.124.broadband7.iol.cz)
Hi all,
This is my first post on here, so thanks in advance for reading it
I am pretty new to PHP, but comfortable with programming techniques (mainly in AS2).
I am trying to set up this example to use variables for colours in my CSS:
[
www.barelyfitz.com]
(a great concept).
Somehow when testing locally the variables are not being saved, and the css class is not being applied correctly:
This is the CSS (php) code in CSS/style.php:
<?php
header("Content-type: text/css"
;
$boldHeader = '#191b70';
$contentBG = '#ececec';
$subHeader = '#60b30b';
$pageBG = '#2e2e2e';
$bodyText = '#2e2e2e';
$attnColour = '#fe3600';
?>
#wrap
{
background-color:<?=$boldHeader?>;
}
and the CSS file is included in the page as follows:
<link href="CSS/style.php" rel="stylesheet" type="text/css" media="screen"/>
When I upload it to my webspace (jm3d.co.uk) it works fine and the background colour is applied to <div id='wrap'></div> as expected, but under my WAMP5 1.7.3 install this does not work.
If I run this:
<?php
phpinfo();
?>
all appears to be working fine, and in other scripts I have written, variables are working perfectly, but not this one ;(
As I said, it is working on my webspace:
[
www.jm3d.co.uk]
but not locally.
Anyone any ideas?
Thanks a bunch ;l)
Jamie
Post Edited (11-09-07 20:37)
The world is big, the web is bigger