You can use Google Search API to find related post of your site base on title in wordpress. You can check it in my website:
http://pcwilleasy.co.cc/
or
http://pcwilleasy.co.cc/technology-t...-in-each-post/
It have function like
Quote:
|
AskApache Google 404 is a sweet and simple plugin that takes over the handling of any HTTP Errors that your blog has from time to time. The most common type of error is when a page cannot be found, due to a bad link, mistyped URL, etc.. So this plugin uses some AJAX code, Google Search API'S, and a few tricks to display a very helpful and Search-Engine Optimized Error Page. The default displays Google Search Results for images, news, blogs, videos, web, custom search engine, and your own site. It also searches for part of the requested filename that was not found, but it attaches your domain to the search for SEO and greater results.
|
http://www.askapache.com/seo/404-goo...ss-plugin.html
but my code have display not videos, image only some result of your website.
Every can me a idea that is good or not.
Here is the code:
Code:
<p>Related post</p>
<head>
<script src="http://www.google.com/jsapi" type="text/javascript">
</script>
<script language="Javascript" type="text/javascript">
google.load("search", "1");
function OnLoad() {
var searchControl = new google.search.SearchControl();
searchControl.setResultSetSize(google.search.Search.SMALL_RESULTSET);
var webSearch = new google.search.WebSearch();
webSearch.setSiteRestriction('pcwilleasy.co.cc');
options = new google.search.SearcherOptions();
options.setExpandMode(google.search.SearchControl.EXPAND_MODE_OPEN);
searchControl.addSearcher(webSearch, options);
searchControl.draw(document.getElementById("searchcontrol"));
document.getElementById('searchcontrol').firstChild.style.width='100%';
searchControl.execute("<?php the_title(); ?>");
}
google.setOnLoadCallback(OnLoad);
</script>
</head>
<body>
<div id="searchcontrol">Loading...</div>
</body>
</html>
change the webSearch.setSiteRestriction('pcwilleasy.co.cc');
with your website.