If you add .erb to the file (<stylesheet>.css.erb) Rails will parse it before rendering.

-----Oprindelig meddelelse-----
Fra: rubyonrails-talk@googlegroups.com På vegne af Felipe Pieretti Umpierre
Sendt: 22. februar 2012 22:20
Til: rubyonrails-talk@googlegroups.com
Emne: [Rails] Problems with background-* - css

Hello guys, I had made a css file and link to my rails app, but, my background and others parameters in my css file.

an example:

* {font-family:Tahoma, "Trebuchet MS", Arial, Helvetica, sans-serif; font-size:13px;}
body {background: url(image_path( 'bg.jpg' )) fixed no-repeat; width:100%; height:100%; -webkit-background-size: cover;
-moz-background-size: cover; -o-background-size: cover; background-size:
cover;}
.mTopZ {margin-top:0 !important;}

.fLeft {float:left !important;}
.fRight {float:right !important;}
.wrap {width:990px; margin:0 auto; overflow:hidden;}
.wrapS {width:947px; margin:0 auto !important; overflow:hidden;}
.clear {clear:left;}
.wTotal {width:100%; float:left;}
.margin {margin-top:20px; margin-bottom:20px;}
.bradius {-webkit-border-radius: 5px; -moz-border-radius: 5px;
border-radius: 5px;}
.bradius_rz {-webkit-border-radius: 5px 0 5px 5px; -moz-border-radius:
5px 0 5px 5px; border-radius: 5px 0 5px 5px;}

header {width:100%; float:left; overflow:hidden;}

header #user {display:inline-block; overflow:hidden; width:100%;}
header #user .gradient_green {margin-top:27px;}
header #user img {float:left; margin-top:19px;}
header #user h1 {font-size:13px; color:#FFF; margin:30px 0 0 15px; width:240px; float:left;}
header #user form {float:left; margin-top:25px;}
header #user form input[type="text"]
{background:url(../images/inputSearch.png) no-repeat; width:141px; height:36px; border:0; padding:0 10px;}
header #user form input[type="submit"]
{background:url(../images/btSearch.png) no-repeat; width:42px; height:36px; border:0; cursor:pointer;}
header #user form input[type="submit"]:hover {background-position:-0px -36px;}
header #user form input[type="submit"]:active {background-position:-0px -72px;}

header nav {width:auto; margin:0 10px; float:left; overflow:hidden;}
header nav ul li {float:left; width:46px; height:83px;}
header nav ul li a {width:46px; height:83px; float:left;}
header nav ul li .icon1
{background:url('../images/nav-menu/menu_items.png') no-repeat; width:22px; height:23px; margin:29px auto 0 auto;}
header nav ul li .icon2
{background:url('../images/nav-menu/menu_items.png') -23px -0px no-repeat; width:23px; height:22px; margin:29px auto 0 auto;}
header nav ul li .icon3
{background:url(../images/nav-menu/menu_items.png) -47px -0px no-repeat; width:19px; height:23px; margin:29px auto 0 auto;}
header nav ul li .icon4
{background:url(../images/nav-menu/menu_items.png) -67px -0px no-repeat; width:20px; height:23px; margin:29px auto 0 auto;}
header nav ul li .icon5
{background:url(../images/nav-menu/menu_items.png) -0px -24px no-repeat; width:25px; height:23px; margin:29px auto 0 auto;}
header nav ul li .icon6
{background:url(../images/nav-menu/menu_items.png) -26px -24px no-repeat; width:16px; height:22px; margin:29px auto 0 auto;}
header nav ul li .icon7
{background:url(../images/nav-menu/menu_items.png) -43px -24px no-repeat; width:18px; height:23px; margin:29px auto 0 auto;}
header nav ul li .icon8
{background:url(../images/nav-menu/menu_items.png) -62px -24px no-repeat; width:22px; height:22px; margin:29px auto 0 auto;}

header nav ul li:hover {background:url(../images/bgNav.png)
no-repeat; width:46px; height:83px;}

none of thoses background's works, the called is correct, but the image is not called.

Thank's for the help.

--
Posted via http://www.ruby-forum.com/.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.



--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

Search Discussions

Discussion Posts

Previous

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 2 of 12 | next ›
Discussion Overview
grouprubyonrails-talk @
categoriesrubyonrails
postedFeb 22, '12 at 9:20p
activeFeb 24, '12 at 1:54a
posts12
users4
websiterubyonrails.org
irc#RubyOnRails

People

Translate

site design / logo © 2022 Grokbase