Rails erb in inline CSS(in layout file)

Hi,
How can we call rails erb tag in inline CSS
app/layouts/base_layout.rhtml:

    <body>
<style>
    #header {
        background:

url(http://www.google.ca/intl/en_in/images/logo.gif) no-repeat;
}


I want to replace url(http://www.google.ca/intl/en_ca/images/logo.gif)
with
<%= image_tag(@customer_logo.path_to_logo_image, :width => 250, :height
=> 100) %> with out keeping #header in .css file

any help

thanks !!

Srinath A. wrote:

I want to replace url(http://www.google.ca/intl/en_ca/images/logo.gif)
with
<%= image_tag(@customer_logo.path_to_logo_image, :width => 250, :height
=> 100) %> with out keeping #header in .css file

image_path() ?

Exactly as you described should work.

On Feb 18, 10:17 am, “Srinath A.” [email protected]

I don’t think you want to put an image tag there, probably just
something like this instead:

#header { background: url(<%= @customer_logo.path_to_logo_image %>) no-repeat; }

On Feb 18, 10:30 am, “Srinath A.” [email protected]

Hi,
but i code like this :

#header { background: url(<%= image_tag(@customer_logo.path_to_logo_image, :width => 250, :height => 100) %>) no-repeat; }

this is producing error…

Jeff Emminger wrote:

Exactly as you described should work.

On Feb 18, 10:17�am, “Srinath A.” [email protected]