daled Posted August 28, 2007 Share Posted August 28, 2007 the background I want is either sumarticle.gif or .png (both are files), but the link doesn't work: .sumarticle { overflow:hidden; height:100px; width:100%; float:left; padding-left:5px; background:url("sumarticlebg.gif"); background-position:top right; } <div class='sumarticle'>words</div> Why doesn't my background show up? Quote Link to comment https://forums.phpfreaks.com/topic/66975-solved-background-not-working/ Share on other sites More sharing options...
moberemk Posted August 28, 2007 Share Posted August 28, 2007 Use no quotes in the url declaration. Quote Link to comment https://forums.phpfreaks.com/topic/66975-solved-background-not-working/#findComment-335900 Share on other sites More sharing options...
Lamez Posted August 28, 2007 Share Posted August 28, 2007 make it like this background: url('img/logo.gif'); Quote Link to comment https://forums.phpfreaks.com/topic/66975-solved-background-not-working/#findComment-335909 Share on other sites More sharing options...
spamoom Posted August 28, 2007 Share Posted August 28, 2007 i use background-image: url("logo.gif"); Quote Link to comment https://forums.phpfreaks.com/topic/66975-solved-background-not-working/#findComment-336000 Share on other sites More sharing options...
daled Posted August 28, 2007 Author Share Posted August 28, 2007 quotes, no quotes, slashes, not working. Quote Link to comment https://forums.phpfreaks.com/topic/66975-solved-background-not-working/#findComment-336251 Share on other sites More sharing options...
moberemk Posted August 28, 2007 Share Posted August 28, 2007 Is sumarticle.gif in the same folder as the CSS? Because otherwise it won't work unless you write out the full path to the image (IE either ../images/sumarticle.gif or /images/sumarticle.gif, depending on how your server is set up). Quote Link to comment https://forums.phpfreaks.com/topic/66975-solved-background-not-working/#findComment-336260 Share on other sites More sharing options...
daled Posted August 28, 2007 Author Share Posted August 28, 2007 everything's in the same folder. all the pages, images, css, everything. the first time i edited the css putting this image in, it worked the first two times I viewed the page then after that didn't. Quote Link to comment https://forums.phpfreaks.com/topic/66975-solved-background-not-working/#findComment-336315 Share on other sites More sharing options...
moberemk Posted August 28, 2007 Share Posted August 28, 2007 background-image:url(sumarticlebg.gif); Try that. Quote Link to comment https://forums.phpfreaks.com/topic/66975-solved-background-not-working/#findComment-336563 Share on other sites More sharing options...
daled Posted August 29, 2007 Author Share Posted August 29, 2007 did, got nothing. now, the background for another class works. Quote Link to comment https://forums.phpfreaks.com/topic/66975-solved-background-not-working/#findComment-336916 Share on other sites More sharing options...
daled Posted August 29, 2007 Author Share Posted August 29, 2007 i made another file and that works, i think there was something wrong with the source file. solved. Quote Link to comment https://forums.phpfreaks.com/topic/66975-solved-background-not-working/#findComment-336931 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.