hi

is there any way to have individual css for specific pages? I am thinking on something similar to what it can be done with page.tpl.php. Something like having different names for css files : style.css -> general css, front.css - front titled node, data.css -> data/* nodes or similar.

thanks

enrike

Comments

modul’s picture

You can include <style> ..... </style> parts in your nodes, so you can style every node individually, should you want to. Or you could check for node id's in page.tpl.php (with arg(2), I think), and then, accordingly, connect different stylesheets if the node id is such or such.

When your screen is made with Views, you can include individual css files for each different view.

Probably there are many more ways, but this could help you on the way.

schildi’s picture

The module you are looking for is probably "node style".

urrestieta’s picture

is there such a module for drupal?

modul’s picture

When you're looking for a node styling module with the name of "node style", it makes sense to use the search terms "node style", and lo and behold: http://drupal.org/project/node_style .

urrestieta’s picture

for that first you need to know you're looking for a node styling module with the name of "node style".
sorry i did not understand he meant an actual existing module. thanks

urrestieta’s picture

I have some php to get a different ID at the BODY tag. I guess this might be the way to go. I want all nodes under /section1 to share same css and so on with different sections. The script is using explode('/', $uri_path); to break the URL into parts so i might be able to use this. i guess i need to do some php ...
thanks