Use WordPress to Setup Multi Blogs Under One Mysql Database

We can use Mu to setup multi wordpress blogs. If you do not want to do so, you can use wordpress to setup multiy blogs also.  For example, we want to set up two blogs: www.glassespeople.com ,and http://blog.glassespeople.com, we only add the following code at wp-config.php:

How to control WordPress 3.0 tag cloud font size?

Go to wp-includes, use dreamweaver to open category-template.php, search the following code: function wp_tag_cloud( $args = ” ) {  $defaults = array(   ‘smallest’ => 8, ‘largest’ => 22, ‘unit’ => ‘pt’, ‘number’ => 45, then change smallest font size and largest size as you like, say:  function wp_tag_cloud( $args = ” ) {  $defaults = […]

2 Methods to show wordpress lastest posts at other site

Method one, we can show other wordpress posts at our site by using  simplepie.inc, download a wordpress plugin, named “simplepie-core”, and upload simplepie.inc to your site root, you can rename simplepie.inc to other name also, ie, eyeglassframes.inc. Then add the following code at your own site .php file.

How to change wordpress post author name?

Sometimes we want to change wordpress posts author name, if you only need to change several posts, and you do not know the skills, you can delete and repost with the new author name. If you need to modify hundreds posts with the same author, how to do then?

How to display wordpress posts outside the blog?

For example, your main site is http://www.glassespeople.com ,and your blog is http://www.glassespeople.com/blog. If you want so 5 latest post description at www.glassespeople.com, how to do? Simple, the following code will meet your needs: // Include WordPress define(‘WP_USE_THEMES’, false); require(‘blog/wp-load.php’); query_posts(‘showposts=5’); ?> <?php while (have_posts()): the_post(); ?> <h2><?php the_title(); ?></h2> <?php the_excerpt(); ?> <p><a href=”<?php the_permalink(); […]

How to add 10 hot wordpress posts

If you want to add 10 host post at your right bar, just copy and past the following code: <h2>Hot PHP Posts</h2> <ul> <?php $result = $wpdb->get_results(“SELECT comment_count,ID,post_title FROM $wpdb->posts ORDER BY comment_count DESC LIMIT 0 , 10″); foreach ($result as $post) { setup_postdata($post); $postid = $post->ID; $title = $post->post_title; $commentcount = $post->comment_count; if ($commentcount […]

How to control WordPress 9.2 tag cloud font size?

We all know that WP has added widget_tag_cloud_args filter, you can use this function to override the default arguments that are passed to the wp_tag_cloud function to change the tag cloud font size you like. This filter provides a keyed array, where the smallest, largest, and unit keys represent the smallest font size, the largest […]

Add WordPress Category Description

Usually wordpress category description does not show even we add each wordpress category description at WP Administration Panel. Any method to show category description? Yes! Follow me: Go to Appearance –> Editor, and click Category Template (category.php) .  Add <div><strong><?php single_cat_title(‘Currently browsing’); ?> </strong>: <?php echo category_description(); ?></div>  at proper place.

Add one adsens ads except homepage.

It is very simple, copy the following code, and change YOU ADSENSE ADS CODE HERE. to your ads code. done!  <div class=”storycontent”> <?php if (($wp_query->current_post == 0)and (!is_home())) : ?> <div style=”float:right”><br> YOU ADSENSE ADS CODE HERE. </div> <?php endif; $postcnt++; ?>   <?php the_content(__(‘(more KINGPHP details…)’)); ?>  </div>

WordPress Posts not indexing on Google

We are adding regular content everyday but for the past few weeks Google don’t seem to index the new posts at all. Usually they were indexing within a few minutes.  At first I think their must be something wrong with my web hosting or SSL, so I changed the hosting from hostgator to dreamhost, same […]