how to disable wordpress post revisions

disable wordpress post revisions and increase wordpress performance. For improving the WordPress website or blog performance you need use following method.

WordPress saves the post revisions after every 2 min. That takes so much mysql storage.
To save MySQL storage, some WordPress user will be happy using this method, this method is Disable WordPress Post Revision.

how to disable wordpress post revisions

Why we need disabled this featured?

It’ because WordPress created such as dummy data revision and this one make our table sized increased. And if you have limited space, this is bad idea, and of course disable Post Revision also made your WordPress running faster.

Open your wp-config.php file and put the following code in that file. If you are not wordpress developer then dont use following code. Please consult with any wordpress developer for this code.

/* disable post-revisioning nonsense */
define('WP_POST_REVISIONS', FALSE);

Media Library not displaying images after importing posts

Earlier I have blog in wordpressmu  then after wordpress 3.0 version I decided to migrate to new version. I exported my all posts by using the wordpress  export tool. Then I imported data into new wordpress installation. I got all my posts and category and all the data. Then I checked all my attachments.

Then I saw my media library I saw all the images listing are there but images are not showing in media library. Media Library not displaying images after importing posts. I personally faced issue and got frustrated. then I solved issue myself using mysql query trick.

Media Library not displaying images after importing posts

Media Library not displaying images after importing posts
Media Library not displaying images after importing posts

When I checked my database I saw the all the my attachments are listed in post table but images are not displaying. All the places I only saw the wp-includes/images/crystal/default.png image.

I did spend one hour googled for solving the issue but I did not find any solution for this. Than again I checked my Folder permissions and images files but I found all things are perfect.
Then I checked my database and I found the issue. in wp_posts table ->post_mime_type column one entry was missing. After seeing that issue I fixed the issue.

I used the following mysql quires using myphpadmin tool.

[viral-lock message=”Solution code is Hidden! It’s Visible for Users who Liked/Shared This article on Facebook or Twitter or Google+. Like or Tweet this article to reveal the content.”]

Update wp_posts set post_mime_type='image/jpg' WHERE guid like '%jpg%'
Update wp_posts set post_mime_type='image/jepg' WHERE guid like '%jepg%'
Update wp_posts set post_mime_type='image/png' WHERE guid like '%png%'
Update wp_posts set post_mime_type='image/gif' WHERE guid like '%gif%'

[/viral-lock]

After using above query I checked the my media library. I am able to see my all images in media library.

My advise to you is first take backup of your database and then use above mysql quires. Then use the above queries.

If you are imported post from other website then use following commands also.


UPDATE wp_posts SET post_content = REPLACE(post_content, 'NEW-DOMAIN-NAME', 'files/');

UPDATE wp_posts SET post_excerpt = REPLACE(post_excerpt, 'NEW-DOMAIN-NAME', 'OLD-DOMAIN-NAME');

UPDATE wp_posts SET guid = REPLACE(guid, 'NEW-DOMAIN-NAME', 'OLD-DOMAIN-NAME');

Above quires will change the domain location of file.

most popular posts wordpress without plugin

Many times you want to show the popular posts in your wordpress theme and you use popular post wordpress plugin or widget for showing the popular posts in your wordpress theme. As much possible you need to avoid the wordpress plugins for minimal code.

most popular posts wordpress without plugin

With very easy steps you can fetch the most popular posts from your wordpress. Most common trick or technique is on comments base you can fetch the popular posts.

You just need to open your functions.php file from wordpress posts and put following code in file.


// Get Most Popular Posts in theme
function popular_posts_by_comments( $posts = 5) {
 $popular = new WP_Query('orderby=comment_count&posts_per_page='.$posts);
 while ($popular->have_posts()) : $popular->the_post();
?>
<li>
<div>
 <a title="<?php the_title(); ?>" href="<?php the_permalink() ?>"><?php the_title(); ?></a>
 <span><?php comments_popup_link('0 Comment', '1 Comment', '% Comments', 'comments-link', ''); ?></span>
 </div> <!--end .info-->
 <div></div>
</li>
<?php endwhile;
}

This is very easy code to fetch you wordpress popular posts. Here I am fetching only 5 popular posts from wordpress. You can fetch the multiple popular posts by changing the $post variable value.

In wordpress theme sidebar or footer section if you want to show the popular post then just use following code.

popular_posts_by_comments();

most popular posts wordpress without plugin
most popular posts wordpress without plugin

where you want to show the popular posts.

show popular posts without wordpress plugin in theme
show popular posts without wordpress plugin in theme

how to serve wordpress images from subdomain

creating sub domain for wordpress images is best way to increase your wordpress site speed. We given steps to, how to serve wordpress images from sub domain. Many shared hosting and wordpress bloggers and  websites are using the apache web server for hosting the wordpress sites. Apache Web server is having his own rules and behavior. By default when you open webpage of your website. That time you are making so many requests to apache web server with same domain name. That will create queue to apache web server with same domain name.

how to serve wordpress images from subdomain

For reducing the load time you should keep image file on different sub domain. Means though image subdomain you can send a parallel request to Apache web server. It will reduce the concurrent connections to web server. WordPress provides the functionality to set different domain or sub domain for images.

In this article I will show you how easily you can set the wordpress images from sub domain. First create subdomain through your control panel. Use following step for creating subdomain.

how to serve wordpress images from subdomain
how to serve wordpress images from subdomain

I recommend to create the images subdomain because images subdomain is good for SEO. Here I created the purabtech.in/files/ subdomain for my images. Then set your wordpress images path in document root setting. Normally your wordpress images are stored in wp-content/uploads directory. You can use following setting for setting the document root.

how to serve wordpress images from subdomain
how to serve wordpress images from subdomain

After creating subdomain for images and setting up the correct document root for images subdomain. Go to your wordpress admin panel. From right side panel you should go to settings -> Media panel. This page will look like as follows:

how to serve wordpress images from subdomain
how to serve wordpress images from subdomain

In “Full URL path to files” textbox put your image subdomain name and click on save changes button. Uncheck the organize my uploads into month- and year-based folder option because which is not good for SEO purpose.

After this your images will come from image subdomain but old uploaded image files will still come from older location and same domain. For changing the older images file location and domain information you should use the following steps.

Go to your Mysql databases and select the your wordpress database. You can use the phpmyadmin sql manager for this or you can use command prompt for this if you are having dedicated hosting server. If you taken shared hosting then I recommend to use PhpMyAdmin.

Use following two SQL query: (Note: You should use your images subdomain and your domain name in SQL query)


UPDATE wp_posts SET post_content = REPLACE(post_content,'http://images.purabtech.in/','http://images.purabtech.in/');

UPDATE wp_posts SET guid = REPLACE(guid,'http://images.purabtech.in/','http://images.purabtech.in/');

After this your old images files will point to images subdomain. If your images and wordpress website is old then google and other search engines already indexed your images. So We need to write the redirection rewrite rule for images in your .htaccess file. This file you will find in your Root directory of wordpress installation.

Use following line of code in your .htaccess file.


RewriteEngine On
RewriteBase /

RedirectMatch 301 ^/wp-content/uploads/(.*)$ http://images.purabtech.in/$1

Above all steps are important to change the wordpress images into images subdoamin. If you are having any issues or questions about this article. Then please write to me.

How to Optimize Your WordPress Database using plugin

When we are using the wordpress sites then we need to clean the database always. If your site is having more than 500 articles then you need to worry about server performance.

How to Optimize Your WordPress Database using plugin

Mysql load will impact your server.  Many people are suggesting to use the WP-DBManager wordpress plugin. But forgot about plugin feature. That plugin specially made for database backup and managing the tables.

If you want to optimize your wordpress database then you need to use wp-optimize wordpress plugin. I found that is only plugin is helpful for really keep optimize your wordpress database.

I used that plugin. Before using that plugin my mysql database size was 135mb. After using that wp-optimize plugin features database size was 4mb. That means my database really optimized. My sites performance was also improved.

I really liked this wordpress plugin. Thanks to Ruhani Rabin who wrote this plugin.

How to Optimize Your WordPress Database using plugin
How to Optimize Your WordPress Database using plugin

You can download this plugin from here:

http://wordpress.org/extend/plugins/wp-optimize/

Simple but effective plugin allows you to extensively clean up your WordPress database and optimize it without doing manual queries.

What is features of wp-optimize?

  • Enable/Disable trackbacks for all published post
  • Enable/Disable comments for all published post
  • Removal of stale post revisions
  • Removal of stale unapproved and spam comments
  • Removal of trashed comments
  • Removal of akismet metadata from comments
  • Removal of other stale metadata from comments
  • Mobile device friendly, now you can optimize your site on the go
  • Removal of all trackbacks and pingbacks
  • Cleaning up auto draft posts
  • Removal of transient options
  • Clear out the post trash
  • Automatic cleanup of all the integrated options (also uses retention if enabled)
  • Ability to keep selected number of weeks data when cleaning up
  • Option to add or remove link on wp admin bar.
  • Enable/Disable weekly schedules of optimization
  • Apply native WordPress MySql optimize commands on your database tables without phpMyAdmin or any manual query.
  • Display Database table statistics. Shows how much space can be optimized and how much space has been cleared.
  • Enabled for Administrators only.

Every-time you save a new post or pages, WordPress creates a revision of that post or page. If you edit a post 6 times you might have 5 copy of that post as revisions. Imagine if your post or pages are long and big. It is a huge number of bytes that’s on your MySQL overhead. Now WP-Optimize allows you to optimize and shrink your posts table by removing not necessary post revisions from the database. As example, if you have a post which is approximately 100KB data and you have 5 revisions of that post, the total space wasted is about 500KB. And if you have 100 posts similar to it, you have 50MB database space wasted.

How to use the the_post_thumbnail In WordPress

Now WordPress in core the new post thumbnail function will not changed until. we have given info about How to use the the_post_thumbnail In WordPress.

use the the_post_thumbnail In WordPress

You can provide 4 picture formats to the function (change the width and height values to your need):

use the the_post_thumbnail In WordPress
use the the_post_thumbnail In WordPress
// the thumbnail
the_post_thumbnail(array(100,100));

// medium resolution
the_post_thumbnail(array(300,200));

// large resolution
the_post_thumbnail(array(600, 400));

// original
the_post_thumbnail();

You can set how the images should align. It is also possible to assign an own class:

//  left align
the_post_thumbnail(array(100,100), array('class' => 'alignleft'));

//  right align
the_post_thumbnail(array(100,100), array('class' => 'alignright'));

//  center
the_post_thumbnail(array(100,100), array('class' => 'aligncenter'));

// align right and the class  'my_own_class'
the_post_thumbnail(array(100,100), array('class' => 'alignright my_own_class'));

The 3rd possibility is the control of the images size with an array of height and width:
For this purpose we suppose that the settings for thumbnail is 150×150, for medium 300×200 and for large 600×400.

// thumbnail scaled to 60x60 pixel
the_post_thumbnail(array(60,60), array('class' => 'alignleft'));

// original thumbnail
the_post_thumbnail(array(150,150), array('class' => 'alignleft'));

// medium resolution scaled to 200x133 pixel
the_post_thumbnail(array(200,200), array('class' => 'alignleft'));

// large resolution scaled to 400x266 Pixel
the_post_thumbnail(array(400,345), array('class' => 'alignleft'));

We see that the image proportions are always maintained, even if one specifies crooked values.

For the Theme Designers is this not necessarily easier, because no one knows what the user will put in his settings o his library. One way to approach this problem, to query the options for the various sizes:

// width of the thumbnails
get_option('thumbnail_size_w');

//  height of the thumbnails
get_option('thumbnail_size_h');

//  height of the medium resolution
get_option('medium_size_h');

//  width of the large resolution
get_option('large_size_w');

//  1 = Crop thumbnail to exact dimensions, 0 = Crop off
get_option('thumbnail_crop')

You can change these values in your theme.

$w = get_option('thumbnail_size_w') / 2;
$h = get_option('thumbnail_size_h') /2;

the_post_thumbnail(array($w, $h), array('class' => 'alignleft'));

Here another example: If the size of a thumbnail is bigger than 100×100 and crop is activated, then the thumbnail should be resized to 100×100, otherwise use the original thumbnail.

if(get_option('thumbnail_size_w') > 100 && get_option('thumbnail_crop') == 1) {
    the_post_thumbnail(array(100,100));
}else{
    the_post_thumbnail('thumbnail');
}

What Matt is saying?

I wouldn’t recommend anyone use the named arguments for the_post_thumbnail, like ‘thumbnail’, could you remove those from your tutorial.

Inspired by

How to publish wordpress feeds later

When you publish your post,the feed an published to the whole world.That’s very annoying thing. publish wordpress feeds later, That is always good from SEO.

How to publish wordpress feeds later

How to publish wordpress feeds later
How to publish wordpress feeds later

Some times you need to change the content or change the url, that time you got the errors

The following example publishs the post 10 minutes later in your feed:


/**
 * puplish the content in the feed later
 * $where ist default-var in WordPress (wp-includes/query.php)
 * // Apply filters on where and join prior to paging so that any
 * This function an a SQL-syntax
 */
function publish_later_on_feed($where) {
 global $wpdb;

 if ( is_feed() ) {
 // timestamp in WP-format
 $now = gmdate('Y-m-d H:i:s');

 // value for wait; + device
 $wait = '10'; // integer

 // http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functions.html#function_timestampdiff
 $device = 'MINUTE'; //MINUTE, HOUR, DAY, WEEK, MONTH, YEAR

 // add SQL-sytax to default $where
 $where .= " AND TIMESTAMPDIFF($device, $wpdb->posts.post_date_gmt, '$now') > $wait ";
 }
 return $where;
}

add_filter('posts_where', 'publish_later_on_feed');

You need to open the your wordpress themes functions.php file and put above code in that file. Using this function your feed will publish after 10 minute of your wordpress post publishing.

How to wordpress change admin username

You cannot change a WordPress.com account username once it has been set. However, you can change what is seen on your posts and comments by changing the display name (nickname) in your profile, or you can create a new account and transfer your blog(s) to the new account.

How to wordpress change admin username

wordpress change admin username
wordpress change admin username

Change Display Name (Nickname)

1. Access your User Profile

2. Change the value next to Display name publicly as under Basic Details

3. Click Update Profile.

↑ Table of Contents ↑

Change Username

1. Log into your current account (using your existing username)

2. Access your Personal Settings and change the e-mail address to another email address. This will free up your primary e-mail for use with the new username.

3. Once the new address has been verified via email confirmation, log out of the account.

4. Go to http://wordpress.com/signup/ and attempt to register a new account (the username you wish to change to) with your e-mail address.

5. If you’ve got a blog you should transfer its ownership to your new username.

Once you’ve done all of that you’ll be rocking WordPress.com with your new username.

via Change Your Username « Support.

5 tips to increase wordPress traffic and look

In article, I explained you the 5 best tips about how to keep your wordpress blog or website impressive and 5 tips to increase wordPress traffic and look. It is very important to increase wordPress traffic by doing some tricks. There are many ways for increase wordPress traffic. But here in this article, I found some very unique increase wordPress traffic tips which are very useful for every web master.

I also did many tricks for my client to increase wordPress traffic. So think deeply about, how to increase wordPress traffic.

increase wordPress traffic

WordPress is becoming most popular CMS these days. It is very easy to use and great search engine support. Following are simple steps which I used to increase wordPress traffic.
Last year wordpress left behind all the cms. Many people are thinking about how to keep the there wordpress site impressive.
In this article I am going tell you the 5 best tips about how to keep your wordpress blog or website impressive.

1. Create a widget controlled footer that keeps visitors busy on site

increase wordPress traffic
increase wordPress traffic

Widget controlled footer is not new thing in wordpress website but still having footer with multiple information is good.
You should keep the following footer widget in website.
1. Recent posts
2. Popular Post
3. Recent Comments
For recent comments you can use following code in footer without plugin

<?php
 $my_query = new WP_Query('showposts=15');
 while ($my_query->have_posts()) : $my_query->the_post();$do_not_duplicate = $post->ID;
?>

For popular post We can use the wp-popular-post plugin. Using that plugin use can use following code in your website

<?php get_mostpopular("range=weekly&order_by=views&stats_comments=0&limit=20"); ?>

For showing the Recent comments you can use following code without any wordpress plugin. You can change the css code as per your site layout.

<?php
$total_comments = $wpdb->get_results("SELECT comment_date_gmt, comment_author, comment_ID, comment_post_ID, comment_author_email, comment_content FROM $wpdb->comments WHERE comment_approved = '1' and comment_type != 'trackback' ORDER BY comment_date_gmt DESC LIMIT 11");
$comment_total = count($total_comments);
echo '<ul>';
for ($comments = 0; $comments < $comment_total; $comments++) {
echo "<div style='clear:both;width:355px;padding-top:3px;'><div style='float:left;width:35px;'>";
echo get_avatar($total_comments[$comments]->comment_author_email,$size='32',$default='<path_to_url>' );
echo "</div> <div style='width:320px;'>";
echo '<li>';
echo $total_comments[$comments]->comment_author . ' says ';
echo '<a href="'. get_permalink($total_comments[$comments]->comment_post_ID) . '#comment-' . $total_comments[$comments]->comment_ID . '">';
// echo get_the_title($total_comments[$comments]->comment_post_ID);
echo $total_comments[$comments]->comment_content;
echo '</a></li></div></div>';
}
echo '</ul>'
?>

2. Display the interesting images on the homepage

You can increase wordPress traffic and website will look cool with best custom made images.
You can use following code for showing the images on homepage.
First you need to open the functions.php file from your wordpress theme folder and copy paste following code in that file.

function get_first_image($id) {
$PostID = $id;
$all_images =& get_children('post_type=attachment&post_mime_type=image&post_parent=' . $PostID );

if($all_images) {
$arr_of_all_images = array_keys($all_images);
$firstImage = $arr_of_all_images[0];
$thumb_url = wp_get_attachment_thumb_url($firstImage);
$First_thumb_image = '<a href="' . get_permalink() . '">' .
 '<img src="' . $thumb_url . '" width="150" height="150" alt="Thumbnail Image" title="Thumbnail Image" />' .
 '</a>';
 echo $First_thumb_image;
 }
}

In your index.php file you need to copy paste the following code for showing the image.

<?php get_first_image($post->ID);  ?>

3. Add social media links to the bottom of post

Visitors always want to bookmark the website or your posts.
So keeping that very simple adding the social media links to your posts is very nice.
Finding the good social media icons as per your website is very easy with google.

There are some nice wordpress plugins available for adding the social media icons but recommend not to use any wordpress plugin.
Or you can use following code.

<style>
.social_icons{ clear:both; border-top:2px solid #ccc; color:#2266BB; font-size:18px;font-weight:bold;line-height:30px;}
.social_icons ul li {float:left; padding-right:8px;}
</style>
<div >
Bookmark & Share This Post
<ul>
 <li><a rel="nofollow" target="_blank" href="http://images.purabtech.in/feed" title="RSS"><img src="http://images.purabtech.in/rss_32.png" title="RSS" alt="RSS"  /></a></li>
 <li><a rel="nofollow" target="_blank" href="http://del.icio.us/post?url=<?php the_permalink() ?>&title=<?php echo urlencode(the_title('','', false)) ?>" title="del.icio.us"><img src="http://images.purabtech.in/delicious_32.png" title="del.icio.us" alt="del.icio.us"  /></a></li>
 <li><a rel="nofollow" target="_blank" href="http://www.stumbleupon.com/submit?url=<?php the_permalink() ?>&title=<?php echo urlencode(the_title('','', false)) ?>" title="StumbleUpon"><img src="http://images.purabtech.in/stumbleupon_32.png" title="StumbleUpon" alt="StumbleUpon"  /></a></li>
 <li><a rel="nofollow" target="_blank" href="http://digg.com/submit?phase=2&url=<?php the_permalink() ?>&title=<?php echo urlencode(the_title('','', false)) ?>" title="Digg"><img src="http://images.purabtech.in/digg_32.png" title="Digg" alt="Digg"  /></a></li>
 <li><a rel="nofollow" target="_blank" href="http://twitthis.com/twit?url=<?php the_permalink() ?>" title="TwitThis"><img src="http://images.purabtech.in/twitter_32.png" title="TwitThis" alt="TwitThis"  /></a></li>

 <li><a rel="nofollow" target="_blank" href="http://www.mixx.com/submit?page_url=<?php the_permalink() ?>&title=<?php echo urlencode(the_title('','', false)) ?>" title="Mixx"><img src="http://images.purabtech.in/mixx_32.png" title="Mixx" alt="Mixx"  /></a></li>
 <li><a rel="nofollow" target="_blank" href="http://technorati.com/faves?add=<?php the_permalink() ?>" title="Technorati"><img src="http://images.purabtech.in/technorati_32.png" title="Technorati" alt="Technorati"  /></a></li>
 <li><a rel="nofollow" target="_blank" href="http://www.facebook.com/sharer.php?u=<?php the_permalink() ?>&t=<?php echo urlencode(the_title('','', false)) ?>" title="Facebook"><img src="http://images.purabtech.in/facebook_32.png" title="Facebook" alt="Facebook"  /></a></li>
 <li><a rel="nofollow" target="_blank" href="http://www.newsvine.com/_tools/seed&save?u=<?php the_permalink() ?>&h=<?php echo urlencode(the_title('','', false)) ?>" title="NewsVine"><img src="http://images.purabtech.in/newsvine_32.png" title="NewsVine" alt="NewsVine"  /></a></li>
 <li><a rel="nofollow" target="_blank" href="http://reddit.com/submit?url=<?php the_permalink() ?>&title=<?php echo urlencode(the_title('','', false)) ?>" title="Reddit"><img src="http://images.purabtech.in/reddit_32.png" title="Reddit" alt="Reddit"  /></a></li>
 <li><a rel="nofollow" target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&bkmk=<?php the_permalink() ?>&title=<?php echo urlencode(the_title('','', false)) ?>" title="Google"><img src="http://images.purabtech.in/google_32.png" title="Google" alt="Google" /></a></li>

 <li><a rel="nofollow" target="_blank" href="http://myweb2.search.yahoo.com/myresults/bookmarklet?u=<?php the_permalink() ?>&=<?php echo urlencode(the_title('','', false)) ?>" title="YahooMyWeb"><img src="http://images.purabtech.in/yahoobuzz_32.png" title="YahooMyWeb" alt="YahooMyWeb"  /></a></li>

 <li><a rel="nofollow" target="_blank" href="mailto:?subject=<?php echo urlencode(the_title('','', false)) ?>&body=<?php the_permalink() ?>" title="E-mail this story to a friend!"><img src="http://images.purabtech.in/email_32.png" title="E-mail this story to a friend!" alt="E-mail this story to a friend!"  /></a></li>

</ul>
</div>

4. Install the Tweetmeme style Twitter button to your posts

Twitter is very popular these days. Twitter is micro blogging website.
So many people want to share there articles with twitter and Many visitors want to share article with there friends and follower by tweeting the article.
I recommend to use the tweetmeme wordpress plugin for putting the Twitter button to your posts.

You can download the tweetmeme wordpress plugin from following URL
http://tweetmeme.com

5. Always show the Author information with photo

Many visitors want to know about author. Keeping Author’s information on wordpress website is really good idea.
That will become your website more interesting the user friendly to visitors.
Some people like the specific writing style of author and They want know more information about Author.

In wordpress keeping the users photo and information I will suggest to use the user-photo wordpress plugin.
http://wordpress.org/extend/plugins/user-photo/
After adding following plugin you can use following code in your wordpress posts.

<?php userphoto_the_author_photo(); ?>

how to add thank you message after wordpress comments

Saying thank you is always good manners. In article, i have code for, add thank you message after wordpress comments after adding comments added by users. I got the same request from many of clients for adding the thank you message after putting comments after by the user who comes to site.

It was good to have this functionality. User will remember your site and you should send the thank you email to user for adding the comment to your wordpress website. For professional sites, it is very great functionality.

add thank you message after wordpress comments

In this article I will show how to add custom message after getting comments from users. For this we going use the wordpress api. WordPress filters are very useful. You can find all wordpress hooks and filters in wp-includes/default-filters.php file.

  • Method First
add_filter('comment_post_redirect', 'redirect_after_comment');
function redirect_after_comment($location){
    $newurl = substr($location, 0, strpos($location, "#comment"));
    return $newurl . '?c=y';
}

if($_GET[ 'c' ] == 'y'){
      echo 'Thank you your comemnt';
} 

Open your functions.php file from your active wordpress theme folder. copy paste the following code in that file. This is very simple trick but still it is really useful.

  • Method Second

For this method you need to create the “Thank you” page in wordpress site than open functions.php file and put following code in that file.


// Redirect to thank you post after comment
add_action('comment_post_redirect', 'redirect_to_thank_page');

function redirect_to_thank_page() {
return 'https://purabtech.in/thank-you';
}

Note: do not forget to change your URL thank you URL from code.  Above code will work in new wordpress versions.

 

 

add thank you message after wordpress comments
add thank you message after wordpress comments