Closed ghost closed 12 years ago
Hi, sorry for the delay responding. Been on holiday.
Can you set WP_DEBUG to true, make a change to the scss.php file and tell me if you get the same issue or if there's errors/warnings?
Hello,
Thanks for getting back to me.
I set WP_DEBUG to true and made some changes. The file is still blank and I did NOT get any errors or warnings.
Let me tell you exactly what I am doing in case that will help.
I'm enqueing the files as follows:
function add_php_powered_css() {
if (!is_admin()) {
$styles_dir = BP_ADMIN_URL;
wp_enqueue_style(
'bp_customizer_stylesheet',
"{$styles_dir}/panel/custom/custom_styles.scss.php"
array(),
'1.00'
);
wp_enqueue_style(
'bp_customizer_stylesheet2',
"{$styles_dir}/panel/custom/custom_styles2.scss",
array(),
'1.00'
);
}
}
add_action('init','add_php_powered_css');
Both files have the exact same sample code:
body {background-color:yellow;}
$width:960px;
#body_inner {width:$width;}
Firebug shows that both of these files show up at the following locations:
However, bp_customizer_stylesheet is blank (i.e., the scss.php file) whereas bp_customizer_stylesheet2.css has the following CSS code:
body {
background-color: yellow; }
#body_inner {
width: 960px; }
They also both created a cache file with the contents slightly different.
Here are the contents of the styles2 file (the one WITH content):
a:4:{s:4:"root";s:70:"C:\wamp\www\bp\wp-content\themes\buildpress\admin\panel\custom\wp-sass";s:4:"path";s:82:"C:\wamp\www\bp/wp-content/themes/buildpress/admin/panel/custom/custom_styles2.scss";s:3:"css";s:71:"body {
background-color: yellow; }
#body_inner {
width: 960px; }
";s:7:"updated";i:1345752598;}
Here are the contents of the styles file (the one WITHOUT content):
a:4:{s:4:"root";s:70:"C:\wamp\www\bp\wp-content\themes\buildpress\admin\panel\custom\wp-sass";s:4:"path";s:85:"C:\wamp\www\bp/wp-content/themes/buildpress/admin/panel/custom/custom_styles.scss.php";s:3:"css";s:0:"";s:7:"updated";i:1345747657;}
Any ideas?
Thanks again for your help.
Be well,
Moshe
Hello - I am wondering if you saw my last comment?
Hi sorry - I was looking after my cousin over the weekend. I've fixed this issue now, there was a bug in the way I did the preprocessed file creation logic that I missed. Sorry about that!
No worries - I know the difficulties of balancing life and work and other projects.
Thanks for fixing it - I'll download the new version now.
Take care,
Moshe
It works - thanks :).
Be well,
Moshe
Great! Thanks for using it and for the feedback :)
I can get wp-sass to work with a .scss extension.
However, I cannot get it to work with a .scss.php extension. The cached version of the file shows up in Firebug, but the contents are empty.
The exact same contents will show up in the .scss version.
For instance, I have experimented with this sample content:
body {background-color:yellow;}
$width:960px;
body_inner {width:$width;}
This works fine in the .scss version, but the .scss.php version is totally blank.
Any idea of how to get the .scss.php version to work?
Thanks,
Moshe