Blogroll

Showing posts with label wordpress. Show all posts
Showing posts with label wordpress. Show all posts
Monday, July 16, 2012

13 useful query for wordpress


Change Siteurl & Homeurl

WordPress stores the absolute path of the site URL and home URL in the database. Therefore, if you transfer your WordPress site from the localhost to your server, your site will not load online. This is because the absolute path URL is still pointing to your localhost. You will need to change the site URL and the home URL in order for the site to work.
Solution:
1
UPDATE wp_options SET option_value = replace(option_value, 'http://www.oldsiteurl.com', 'http://www.newsiteurl.com') WHERE option_name = 'home' OR option_name = 'siteurl';

Tuesday, November 8, 2011

Write breadcrums function

This function is really simple.

Show Related Post in WordPress Without a Plugin

Related posts is a very popular feature. My default wordpress installation often includes a plugin that has this functionality. There are quite a few plugins that lets you have this feature