Hi
You need to move your post title/link code inside the Div’s
What you have now looks like this
<div class="top">
<h2><a href="http://www.nadialouiseimages.com/news/?p=1">Hello world!</a></h2>
<div class="bottom">
<p class="categor"><strong>Posted:</strong> under <a rel="category" title="View all posts in Uncategorized" href="http://www.nadialouiseimages.com/news/?cat=1">Uncategorized</a>.<br /></p>
It wants to look like this:
<div class=”top”>
<div class=”bottom”>
<h2>Hello world!</h2>
<p class=”categor”>Posted: under Uncategorized.
</p>
`
I took this from View Source – what you are actually going to see will be partially PHP code. Just move the code that sets up the <h2> </h2> inside the Div that’s below it. That will put it in the grey box area.
Hey,
If you have a look at the php code below, it’s already set out with nothing in “top” (in single.php), which is why I’m wondering why it’s not working.
Any ideas?
<?php get_header(); ?>
<!-- Start of Two Column Fixed Body -->
<div id="main">
<div id="right">
<?php
if (have_posts())
{
while (have_posts())
{
the_post();
?>
<div id="page-<?php echo the_ID();?>" class="<?php echo $alternate;?>">
<div class="back">
<div class="top">
<div class="bottom">
<h2><a href="<?php the_permalink() ?>"><?php the_title(); ?></a></h2>
<p class="categor"><strong>Posted:</strong> <?php the_time('F jS, Y') ?> under <?php the_category(', ') ?>.
<?php the_tags('Tags: ', ', ',''); ?><?php edit_post_link('[e]',' | ',''); ?>
<!--
<h4><a href="<?php the_author_url(); ?>"><?php the_author() ?></a> at <?php the_date() ?> : <?php the_time() ?> <?php edit_post_link(__('Edit This')); ?></h4>
-->
<?php if ( get_post_meta($post->ID, 'heading', true) )
{
?>
<h4><?php echo get_post_meta($post->ID, "heading", $single = true); ?></h4>
<?php
}
?>
<div class="post-body">
<?php the_content('Read the rest of this entry »'); ?>
</div>
<div id="comment">
<?php comments_template(); ?>
</div>
</div>
<?php
}
?>
<?php
}else{
// No Post Found
?>
<div id="errobox" style="padding-left:10px">
<h2 class="center">404 Not Found</h2>
<p class="center">Sorry, but you are looking for something that isn't here.
</div>
<?php
}
?>
</div>
</div>
</div>
</div><!-- End of Column Left -->
<div id="left">
<?php get_sidebar(); ?>
</div><!-- End of Column Right -->
<div style="clear:both"></div>
</div>
<!-- End of Two Column Fixed Body -->
<?php get_footer(); ?>
Hi – That one looks correct – your home page looks correct also. There are a number of templates that WP uses to put a site together. Its possible the one whose code you posted is not the one that has the problem.
The main ones you want to look at are
index.php
page.php
category.php
archive.php
single.php
Make sure the code in all those looks the same as what you posted.
Thanks so much, in the time I’ve just gone and found the problem – it was in showposts.php, in a very sneaky place I wouldn’t have noticed otherwise.
Cheers.