You’re missing a bunch of ending tags in your index.php, according to code validation; they are probably keeping you from centering the divs you want to center. If you fix your html first, then you’ll have more luck with the CSS. Scroll down on the validation page to see your page source and to locate the errors in your template files.
Wow, thank you Songdogtech. I inherited the management of this site from another person. Is that index.php problem in the WordPress installation itself, or is it in the theme I’m using? (Blank Canvas is the name of the theme.)
I’m about to do an upgrade. Will that fix it, or should I clean things up before I upgrade?
Thanks so much again!
index.php in your theme, not the root index.php. Your theme doesn’t get upgraded at the same way WP does and is seperate code. If you do a manual upgrade and overwrite wp-content and your theme, you delete your theme. Read this: Upgrading WordPress « WordPress Codex, and then work on the code in your theme.
Does auto upgrade leave the theme alone?
Yes, but read Upgrading WordPress beforehand, anyway.
I sure will. Thanks so much again!
Hi Songdogtech,
I can’t find the lines of code (indicated by the validator) in the index.php file for the Blank Canvas theme. Am I looking in the wrong place?
Some might be in source of index.php, but some will be in the text of your posts. Right now, most look like they are in sidebar.php: change the <br /> to <br />
. So first, disable your plugins and widgets first and see if that fixes the centering problem. If not, start with fixing the bad <br />
tags.
Well I still can’t find the error in the header logo, because I can’t find the code that pertains to it. Any idea where to look for that? It’s a simple “alt not specified” but I can’t find the line of code.
Suggestions?
Found it.
Thanks again for all your help!
Looks like you’ve got all the rest fixed. The two that are left aren’t important for correct display. But the header logo is in header.php, so add a alt="image"
to that block of code, like this:
<div id="header">
<?php if (is_single() OR is_page()) { ?>
<h2 id="logo"><a href="<?php echo get_settings('home'); ?>" title="<?php bloginfo('name'); ?>" alt="image"><span><?php bloginfo('name'); ?></span></a></h2>
<div id="description"><?php bloginfo('description') ?></div>
<?php
} else { ?>
<h1 id="logo"><a href="<?php echo get_settings('home'); ?>" title="<?php bloginfo('name'); ?>" alt="image"><span><?php bloginfo('name'); ?></span></a></h1>
<div id="description"><?php bloginfo('description') ?></div>
<?php } ?>
</div><!-- #header -->
And then for the centering, it looks like you added to much left padding in your #footer
in style.css. Reduce it from 225 px and the footer links should be more centered. And with the top links, try floating your #menu
left.
Songdogtech thanks so much for all your help. I’ve got it moving now. As I mentioned, I’m not only a beginner at this, but the skills I do have are rusty.
I really appreciate your time.
Thanks again!
Glad you got it working; it looks good now. We all have to start somewhere!