Is it possible to embed Rails code in a style sheet?
James West
70 posts
|
The book talks about setting colours in a style sheet (depot.css) and I was wondering if it would be possible to have these colours set from a database table which would presumably need ruby code embedded into the depot.css to call a method maybe in the application_helper.rb that reads colours from a database if it has not already read them? |
Jason Frankl...
4 posts
|
div.app_base {
width: 820px;
background-color: <%= model.color =>;
margin-left: auto;
margin-right: auto; |
James West
70 posts
|
Thank you :-) |
3 posts, 2 voices
