wp Query Posts to display in Nivo Slider

Take a look at your code now that I have formatted it. You are opening <div class="slide-caption"> inside the Loop but are not closing it until after the Loop, and you are missing two closing </div> tags altogether (though that may be a copy/paste error). That means the markup is going to be badly broken, which could lead to unexpected behavior.

You should have something like:

<div class="slider-wrapper theme-default">
    <div id="slider" class="nivoSlider"><?php
        $the_query = new WP_Query( 'showposts=5' );
        while ($the_query -> have_posts()) : $the_query -> the_post();
            the_post_thumbnail(); ?> 
            <div class="slide-caption">  
                <h3><?php the_title(); ?></h3>
                <?php the_content(); ?>
            </div>
       <?php endwhile;?>
    </div>
</div>

Always format your code carefully and you will spot this stuff more easily, use a decent code editor that will do syntax highlighting, and you don’t need all those opening and closing <php/?> tags. Only use them when you are actually switching from PHP to HTML. They aren’t line endings or line start-ings.

Edit:

If that second block of code is an example from the NIVO docs, then you are trying to do something that is not supported– at least support is not indicated by that example. It does not appear that you can assign a caption to each image in the slider, but just assign a caption globally.

<div class="slider-wrapper theme-default">
    <div id="slider" class="nivoSlider"><?php
        $the_query = new WP_Query( 'showposts=5' );
        while ($the_query -> have_posts()) : $the_query -> the_post();
            the_post_thumbnail(); ?> 
        <?php endwhile;?>
    </div>
    <div id="htmlCaption" class="nivo-html-caption slide-caption">  
        <h3><?php the_title(); ?></h3>
        <?php the_content(); ?>
    </div>
</div>

I also added htmlCaption as the script might use it.