WordPress.org

Ready to get started?Download WordPress

Forums

Losing Post Formatting When Including Posts in HTML Webpage (2 posts)

  1. borisdollar
    Member
    Posted 2 years ago #

    Theme: twentyeleven

    Hi.

    I use some code which I got from these support pages to insert WP posts into my existing site template.

    However, whilst this works and I can see the posts on my website, some formatting is lost (in particular, wordwrapping around images).

    The code I used is:

    <?php
    include('public_html/wp/wp-blog-header.php');
    ?>

    <?php if ( have_posts() ) : ?>

    <?php twentyeleven_content_nav( 'nav-above' ); ?>

    <?php /* Start the Loop */ ?>
    <?php while ( have_posts() ) : the_post(); ?>

    <?php get_template_part( 'content', get_post_format() ); ?>

    <?php endwhile; ?>

    <?php twentyeleven_content_nav( 'nav-below' ); ?>

    I'm new to WP, so please be gentle!

    The URL of the WP page is http://tinyurl.com/bszovh9

    The URL of the posts on my website is http://tinyurl.com/cel3e82

    As you can see, the formatting on the WP page is fine, but the website loses the formatting of the text around the image.

    Any idea what I'm missing on my HTML page to retrieve formatting info from the WP page?

    Thanks in advance.

  2. borisdollar
    Member
    Posted 2 years ago #

    Any suggestions guys? Have I explained the problem well enough?

    Thanks,

Topic Closed

This topic has been closed to new replies.

About this Topic