i need to include a css style sheet to one of my documents and not the others
im thinking i can use an if statement in side a template for the call ?
[if document id = x , show style1.css, else style2.css ]
whats the best way to do this?
-
MODX Staff
- 12,272 Posts
Is there a lot of overlap in the two stylesheets? If so, there may be better ways to achieve your goal.
Ryan Thrash, MODX Co-Founder
Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
Its badly effecting one of the important pages. being a third party script "modernbill" its not really wise to start hacking their css .
i couldn’t just make a new template and do the css include that way , but would prefer to just see if there is a quick query ? if not then its no worries ill have to just make a separate template.
-
MODX Staff
- 12,272 Posts
I’ve not had problems redoing Modernbill’s css in the past, but I certainly understand the desire to not mess with it. You could do a separate template (what I’d suggest) or you could modify the membercheck snippet to check the doc ID instead of the logged in status to do what you want.
Ryan Thrash, MODX Co-Founder
Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
Try PHX for conditional statements.