Subscribe to my RSS Feed ...... Or if you prefer, Subscribe by Email What is RSS?

Working at Home on the Internet

Helping You Run an Internet Home Business

Fix for WordPress Post Preview

wplogo.jpg 

Some of you may remember my little rant on Saturday about the shortcomings of WordPress 2.2. I was complaining a bit about some of the changes they made with Spacing, Widgets and most of all Post Preview.

I missed my inline Post Preview, and thought the extra step of clicking preview>> and having it open in another window was totally ridiculous. However, Randa Clay mentioned in comments that Will Lee had a fix on his blog, Internet Marketing Fool.

You need to be comfortable working in the background code of your post.php, but it is fairly simple to do. Go to the wp-admin folder on your server, find your post.php and copy & paste.

Here’s the steps Will suggests…

  • Open up your post.php file from your wp-admin directory.
  • Navigate to approximately line 63 and find the following line of code:
  • include('edit-form-advanced.php');

  •  Directly underneath that line, add the following code:
  • ?>
    <div id='preview' class='wrap'>
    <h2 id="preview-post"><?php _e('Post Preview (updated when post is saved)'); ?></h2>
    <iframe src="<?php echo clean_url(apply_filters('preview_post_link', add_query_arg('preview', 'true', get_permalink($post->ID)))); ?>" width="100%" height="600" ></iframe>
    </div>
    <?php

  • Save your changes to post.php.

It really does work, and now I am a little bit happier using WP 2.2. And I would like to thank Will Lee for sharing this code with us to overcome another inconvenience caused by “upgrading” WordPress.

Update: If you Upgrade to WordPress 2.2.1 you will have to perform the same procedure in order to get your Post Preview. It Does Work on the new version as well.

Technorati Tags: ,

New Here? You may want to Subscribe to my RSS feed for daily updates. Or if you prefer, Subscribe by Email What is RSS? Thanks for visiting!


Related Posts:
  • Why Does WordPress Always Break Things That Work When Updating?
  • Beware: Rant Ahead   Why is it that EVERY time that there is an upg...
  • Review of WordPress 2.2, the Bad Things
  • Let me tell you a little story. A few years back, "Irish Spring" was my ...
  • WordPress vs Blogger (preliminary review)
  •  vs Ok, so now that I am mostly moved in, I think it is time to m...

    June 18th, 2007 at 10:28am | Posted by Joe | Tips, WordPress | 8 reader remarks | Print This Post