Postponed (maintainer needs more info)
Project:
Scaffold
Version:
6.x-1.4
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
16 Aug 2010 at 22:34 UTC
Updated:
18 Sep 2010 at 00:11 UTC
Hey, I'm a newbie front-end developer and I'm bad at PHP, so I have no idea what's happening here.
I included my stylesheet in my theme .info. The Module is picking it up, and outputting a CSS file -- but the CSS file isn't being processed by CSSCaffold. It's just the raw text from the CSS file (so @grid and all my constants are still right in there).
I followed your directions -- I downloaded your module, put the "scaffold" folder into it from the github repo you mentioned, and then installed it to my drupal site.
Any ideas why my files might be going through, but aren't being properly processed?
Thanks for your time and awesome work on this module!
Brian
Comments
Comment #1
jide commented@brino,
Things to verify :
- Have you included the stylesheet file using scaffold[all][] syntax ?
- Have you tried with a minimal stylesheet to ensure it has no parsing error ?
- If it still does not work, you may want to manually fill the Document root value in admin/settings/scaffold.
You may also try the dev version since it has some bugfixes.
Comment #2
brino commentedThanks for the response!
1. Yes, I tried scaffold[screen][], scaffold[print][], and scaffold[all][]. The
tag is being generated to the page, but the stylesheet is just the normal CSS, not preprocesed.
2. A normal stylesheet is going through fine, unprocessed by scaffold.
3. I'll play with the doc root a bit more, although it seemed to be correct in the settings.
I'll also give the dev version a shot!
Thanks for taking the time to respond, I really appreciate it!
Brian
Comment #3
brino commentedHi Jide,
Thanks again for responding. I've tracked down the problem. Tao, my base theme, has a preprocess function which strips a lot of the core drupal styles from the page (which is awesome for typographic consistency), but is unfortunately breaking the Scaffold plugin.
I'm a decent JavaScript guy, but not much of a PHPer, so I'm not exactly sure how to resolve this conflict... I may have to finally try my hand at rewriting the preprocess function.
Brian
Comment #4
jide commentedThat's an interesting issue, other themes may do the same, I'll see if this issue can at least have a workaround by tweaking the theme, and if so add instructions in the README.txt file.
Comment #5
brino commentedAwesome. I owe you a beer at the next DrupalCon in the states!
Comment #6
brino commentedErrr, nevermind! Just saw that you're French. I'll have to make it to Copenhagenthen =)
Comment #7
brino commentedAnd sorry to harass you about this, but I thought you might be interested in the following tidbit:
I've thought about switching to LESS, and thought I'd give the LESS module a shot. That module did in fact work with my Tao subtheme, so it may be helpful to review their implementation for a comparison.
Thanks,
Brian
Comment #8
jide commentedHi brino,
Hey, thank you for the beer proposal, but yes, probably not in the US ;) Not even Copenhaguen, I won't be there neither, but some day maybe ;)
To track down the problem, could you tell me :
- What you do exactly ? Use Tao and modify it to add a scaffold stylesheet ? Use it as a base theme ?
- Could you use a very simple stylesheet, like this one :
And see if the stylesheet is processed ?
- Ensure you checked "Development mode" and disabled Drupal css aggregation.
Comment #9
Flying Drupalist commentedI haven't tried this yet but I'm also using Tao so I'll subscribe.
Comment #10
jide commentedNeed more info for this.
Comment #11
razunter commentedSame problem with Zen2-based theme, Scaffold 2.2
Comment #12
jide commentedI quickly looked at the Tao template.php file, and the "styles" variable seems only affected for print stylesheet, so that's not the cause of the problem.
If you have the issue, please try with a modified Garland theme with the minimal stylesheet provided in my previous comment to see if the problem really comes from the theme.
Comment #13
bforchhammer commentedSubscribing... :)
Comment #14
dwillems commentedBuilding a new subtheme of tao and I'm having the same issue. Replaced my stylesheet with the minimal from #8 and still having trouble, switched base theme to garland and it worked fine. Anyone have info on a workaround until a real solution is found?
Comment #15
Josh Benner commentedI've recently built a subtheme of Rubik, which is itself a subtheme of Tao. To use with Scaffold I had to put this in my theme's template.php:
The offending code in Tao is found in tao_preprocess_page(), specifically where it replaces the styles with stuff it gets from tao_css_stripped().
Comment #16
Josh Benner commentedNOTE: My code in #15 does not work with CSS aggregation. I'll be tackling that eventually, though. ;)
Comment #17
Josh Benner commentedOkay, so in looking at this to share, I realized this can be so much easier. Put this in your theme:
This keeps Tao's CSS wrangling AND lets Scaffold process (and aggregate) its CSS files.
Comment #18
jide commentedJosh, thanks for the feedback, it will be useful to add to README.txt. And yes, indeed, the second snippet is much easier :)
Comment #19
razunter commentedBut LESS has no problems with these themes.
Comment #20
gmclelland commentedFYI... I just created an Tao subtheme and everything seems to be working fine for me so far.
Comment #21
brino commentedHey Glenn,
Yes! It looks like the newer version of Tao have actually gone away from a function that was stripping out the CSS aggressively, which caused my initial headaches. Plus, I'd like to note that I've solved another problem I had, where Scaffold was unable to require files properly, by fixing the base_path() for this module. If you have your drupal install in the document root, everything is cool. If not, and you're having problems with this module giving you "PHP can't require '' "errors, check out the bug report i submitted: http://drupal.org/node/914132
Brian