Programming-6

How To Protect Your Blog Against Image Hotlinking

Using the following snippet you will be able to protect your blog against image hotlinking.

Snippet Source/Credit: WPRecipies

How To Search Within Post Type Only

If you want to force the search engine to search only within a specific post type, then all you have to do is simply copy and paste the following code into your theme’s functions.php file. Remember to change the post type name on line 4 and you are done.

Snippet Source/Credit: Hongkiat

How To Automatically Add Twitter And Facebook Buttons To Your Posts

Adding the following snippet to your theme’s functions.php file, you will be able to add Twitter and Facebook buttons to your posts. It will display both Facebook and Twitter buttons at the bottom of this post.

Snippet Source/Credit: WPRecipes

How To Remove Login Shake Effect At The Time When Error Occurs

Using the following snippet will let you remove the login shake effect when error occurs. Simply paste the following code in your theme’s functions.php file and you are done.

Snippet Source/Credit: WordPress Support Forum

How To Add .pdf Support To Your WordPress Blog Media Manager

Copy and paste the following snippet into your theme’s functions.php file and you are done.

Snippet Source/Credit: WP Tuts

Making Translatable JavaScript Strings On Your WordPress Theme

With the help of snippet below, you will be able to make translatable JavaScript strings on your WordPress theme. Make sure you paste the following code into your function.php file.

Snippet Source/Credit: WPTheming.com