Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Wordpress centre text in PHP code

Status
Not open for further replies.

disturbedone

Vendor
Sep 28, 2006
781
AU
Hi, I'm using the Wordpress with MTS Journey theme and in header.php is the following programming....ps I'm a newbie to Wordpress/PHP

<div id="containerl">
<div id="header"><h1><a name="topp" title="topp" id="topp"></a><a href="<?php echo get_settings('home'); ?>/" title="<?php _e('Go to','mtsjourney'); ?> <?php bloginfo('name'); ?> <?php _e('Homepage','mtsjourney'); ?>"><?php bloginfo('name'); ?></a></h1></div>
<div id="wrapper">
<div id="content">

It displays the name of the blog, which is my case is 13 characters and it appears to be centered. I was mucking around as I want to place the blog description there. I got that to work but is several works and it's not centered. I put things back to how they were, made the blog name longer and found that it's also not centered. I've tried putting in 'text-align: center' in several places but it won't centre.

How can this be done?

Cheers
 
I found in style.css was the following programming....

div#containerl {
max-width: 1200px;
width: 97%;
margin: 0 auto;
text-align: center;
border: 3px double #688f9e;
color: #151515;
background-color: #fff;

and although 'text-align; center;' was there it just wasn't working for some reason. I deleted and re-entered it then save it and it's centered.
 
this is not a php question.

you have also posted your question in the wordpress forum, and that is the best starting place.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top