Did you add this to the top of your style.php?:
<?php header("Content-type: text/css"); ?>
Also, to make WordPress look for the correct file, open your header up and add this
<link rel="stylesheet" type="text/css" media="screen" href="style.php">
Hope that works
Alex
Thread Starter
buckza
(@buckza)
Thanks for the quick replay back
I did add <?php header(“Content-type: text/css”); ?>
in the top of my style.php
This is what I have in my header.php
<link rel=”stylesheet” href=”<?php bloginfo(‘stylesheet_url’); ?>” type=”text/css” media=”screen” />
How can I change that
My style.php is in /themes/limau-orange-01/style.php
Simply change
<link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen" />
to
<link rel="stylesheet" href="http://mydomainname.com/wp-content/themes/limau-orange-01/style.php" type="text/css" media="screen" />
Thread Starter
buckza
(@buckza)
thanks
I did change that but not it looks like the stylesheet is not parsing correct
This is what I have in style.php
<?php header(‘Content-type: text/css’); ?>
/* Setup the Variables */
$pagewidth = ‘980px’ /* Width of the Page */
$gutter = ‘5px’ /* Gutter Sise */
$leftwidth = ‘200px’ /* Left Width */
$rightwidth = ‘170px’ /* Right Width */
$fontsizeglobal = ’12px’ /* Global Font Size */
$fontsizeh1 = ’24px’ /* H1 Font Size */
$fontsizeh2 = ’16px’ /* H2 Font Size */
$fontsizeu1 = ’13px’ /* U1 Font Size */
$fontcolor1 = ‘#666’ /* #666 Grey */
$fontcolor2 = ‘#000’ /* #000 Black */
$fontcolor3 = ‘white’ /* #FFF white */
body {
font-family:’Verdana’;
font-size:<? $fontsizeglobal ?>;
}
and this is the output I get when I run it in a browser
/* Setup the Variables */
$pagewidth = ‘980px’ /* Width of the Page */
$gutter = ‘5px’ /* Gutter Sise */
$leftwidth = ‘200px’ /* Left Width */
$rightwidth = ‘170px’ /* Right Width */
$fontsizeglobal = ’12px’ /* Global Font Size */
$fontsizeh1 = ’14px’ /* H1 Font Size */
$fontsizeh2 = ’16px’ /* H2 Font Size */
$fontsizeu1 = ’13px’ /* U1 Font Size */
$fontcolor1 = ‘#666’ /* #666 Grey */
$fontcolor2 = ‘#000’ /* #000 Black */
$fontcolor3 = ‘white’ /* #FFF white */
body {
font-family:’Verdana’;
font-size:;
}
the fontsize is blank where the code to generate that is
font-size:<? $fontsizeglobal ?>;
what am I missing?
Thread Starter
buckza
(@buckza)
I found my mistake after browsing the PHP sites
thanks again – all working now
Maybe it should be…
<link rel="stylesheet" href="<?php bloginfo('template_directory'); ?>/style.php" type="text/css" media="screen" />
Just wondering…