Want to embed WordPress contents on your website?
WordPress is a very flexible system that allows you to easily migrate any functions, widgets and plugins on your website.
To embed WordPress, you need to insert the following tag:
{code}
define('WP_USE_THEMES', false);
if ($page == "Home") {
require('../wp-blog-header.php');
} else {
require('../wp-blog-header.php');
}
?>{/code}
To Display a summary of post(s) on your page:
{code}
query_posts('showposts=X');
while (have_posts()): the_post(); ?>
"; ?>
endforeach;
?>
{/code}
Troubleshooting:
There are know issues of getting an error when inserting WordPress Header. Some PHP Server does not allow server includes.
To get around this, is to use relative link
e.g if you install your blog as:
www.yoursite.com/blog/
to link to wordpress header relatively you would use the link as:
../blog/wp-blog-header.php
Why would you want to embed wordpress or blog on your site?
Blog not only keeps your visitors up to date with the latest news and information about you or your company, but it also helps keeping your site fresh and active. In order to rank higher on search engines, a blog is the best way to keep your site content updated, and acts as candy for search engine crawlers.