i am taking a style that someone else put together, and have a simple question.. the page is currently buried in the site, along with its images.. i moved the images to /public/images the only problem i have is.. how do i access those files in this case... <div id="headerTop" style="background:url(''images/header_bg.gif''); height:60px;"> how do i encode the style attribute to access the images directory in the public directory? thanks! -- Posted via http://www.ruby-forum.com/.
On Oct 16, 2009, at 2:52 PM, Sergio Ruiz wrote:> i am taking a style that someone else put together, and have a simple > question.. > > the page is currently buried in the site, along with its images.. i > moved the images to /public/images > > the only problem i have is.. > > how do i access those files in this case... > > <div id="headerTop" style="background:url(''images/header_bg.gif''); > height:60px;">background:url(''/images/header_bg.gif''); Note the initial / to make the path from your document root absolute.> > how do i encode the style attribute to access the images directory in > the public directory? > > thanks! > -- > Posted via http://www.ruby-forum.com/. > > >Rob Biedenharn http://agileconsultingllc.com Rob-xa9cJyRlE0mWcWVYNo9pwxS2lgjeYSpx@public.gmane.org
Rob Biedenharn wrote:> On Oct 16, 2009, at 2:52 PM, Sergio Ruiz wrote: >> <div id="headerTop" style="background:url(''images/header_bg.gif''); >> height:60px;"> > > background:url(''/images/header_bg.gif''); > Note the initial / to make the path from your document root absolute. > >Yup. Also, never use the style attribute. Use a separate CSS file instead. Best, -- Marnen Laibow-Koser http://www.marnen.org marnen-sbuyVjPbboAdnm+yROfE0A@public.gmane.org -- Posted via http://www.ruby-forum.com/.
got it! thanks for the help, guys.. yes, this file is FULL of problems.. i just need to get transferred over before i start fixing things.. -- Posted via http://www.ruby-forum.com/.
Sergio Ruiz wrote:> got it! thanks for the help, guys.. > > yes, this file is FULL of problems.. > > i just need to get transferred over before i start fixing things..Ouch! I''ve done that myself a few times. Good luck. Best, -- Marnen Laibow-Koser http://www.marnen.org marnen-sbuyVjPbboAdnm+yROfE0A@public.gmane.org -- Posted via http://www.ruby-forum.com/.