Tell me more ×
WordPress Answers is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I have installed a complete blank theme with no CSS in my new wordpress blog. I have been trying to give it a background image but no success.

I am working on blog's content. Blog is very new. So, until content is ready, I want just a background image to appear on my blog and have some text in the middle of the page.

I removed content from footer.php, I removed default post which you see when Wordpress is first involved. I removed content in searchform. php too. I want it all blank for sometime. just want a BG image and some text that displays in the middle of my blog.

I added this line in blank theme's style.css..its not working. ALso where do I add text so it displays in the centre?

body { background: url('http://mysite.com/wp-content/uploads/2012/03/myIMG.jpg')

Can some one please help me out here??

I do not know anything about PHP so I dont knwo where to add text. Please help me. Which php whould I add text to? and also this background image isnt still working. Ichanged it to background-image now

share|improve this question
You're missing a closing ';}' from that line – Vince Pettit Mar 22 '12 at 12:08

closed as too localized by toscho Feb 17 at 22:44

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, see the FAQ.

1 Answer

Background image:

 body { background-image: url('http://mysite...'); }

Text:

 body { text-align: center; }

and in the html file for your main website:

 <html>
    <body>
      <p>MyText</p>
    </body>
 </html>

You could also use some <div> tags with the 'class' attribute combined with margin and padding attributes in CSS to get the text in a more precise area.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.