If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

CSS weird on one type of page

Hi everyone,

My website is www.ironwhisk.com. The right sidebar looks normal until you use the search bar on the right hand side.
If you search for something that doesn't exist (e.g. "asdfasg") then everything is alright. If results do exist (e.g. "chocolate"), the right sidebar moves.

After search you have a div called sidebar-secondary which appears to be inside your content div when it should be outside and looking at the source code I would say it is because you are not closing some divs above (specifically the divs for the posts)

<?php /* If there are no posts to display, such as an empty archive page */ ?>
<?php if ( ! have_posts() ) : ?>
<h1><?php _e( 'Not Found', 'ari' ); ?></h1>
<p><?php _e( 'Apologies, but no results were found for the requested archive. Perhaps searching will help find a related post.', 'ari' ); ?></p>

Looking again, I said to put it in the wrong place. Try closing the div just before the endwhile.

If you look at your source code on the live page you will see that the div is not being closed and will hopefully help you work out where it needs closing in your loop. Sometimes just a bit of trial and error works and this is definitely what is breaking your layout.

This is a section of your source code where you should be able to see that you have 2 divs being opened (the post div and the forlinks div) and only one being closed: