Pesho Posted January 14, 2007 Share Posted January 14, 2007 Hi all,Can somebody tell me how I can set some pattern as a static background, e.g. the background should not move up and down as I scroll the page. Only the page content should move.Also could you tell me how I can set a small image to appear numerous times and thus form the background?10q,Regards,Pesho Quote Link to comment https://forums.phpfreaks.com/topic/34109-setting-static-background/ Share on other sites More sharing options...
wildteen88 Posted January 14, 2007 Share Posted January 14, 2007 When you apply a background and you 'll want it to be static, then add [tt]background-attachment: fixed;[/tt] to your CSSThis then only scroll the content, the background will not move.I'm not sure about your second question. Perhaps provide an illustration Quote Link to comment https://forums.phpfreaks.com/topic/34109-setting-static-background/#findComment-160425 Share on other sites More sharing options...
ToonMariner Posted January 14, 2007 Share Posted January 14, 2007 background: transparent url(../yourpic.jpg) repeat fixed top left; Quote Link to comment https://forums.phpfreaks.com/topic/34109-setting-static-background/#findComment-160445 Share on other sites More sharing options...
Pesho Posted January 14, 2007 Author Share Posted January 14, 2007 Hello and thanks for the replies.Maybe I'm wrong applying what you told me, but it doesn't work. What I did is add in my .css file:.background {background: transparent url(pattern.jpg) repeat fixed top left;background-attachment: fixed;}and then writing the table code as follows:<table width="770" border="0" align="center" cellpadding="10" cellspacing="0" class="background">I guess I make a stupid mistake.10q,Pesho Quote Link to comment https://forums.phpfreaks.com/topic/34109-setting-static-background/#findComment-160630 Share on other sites More sharing options...
Pesho Posted January 14, 2007 Author Share Posted January 14, 2007 Found the problemThanks again! Quote Link to comment https://forums.phpfreaks.com/topic/34109-setting-static-background/#findComment-160645 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.