WordPress Themes, Plugins, Tutorials, Tips And More...

Tag: Snippet Page 3 of 12

Snippets Collection – 1 Of 5

How To Disable WordPress Comments Completely

The following snippet will let you disable WordPress comments completely.

Snippet Source/Credit: aotearoawebdesign.co.nz

How To Add PayPal Button To Your WordPress Website

Using the following snippet will let you add PayPal button to your WordPress website. Remember to add the snippet to your theme’s functions.php file and you are done.

Snippet Source/Credit: Snipplr

How To Deactivate All WordPress Plugins

Using the following line of snippets, you will be able to deactivate all WordPress plugins.

How To Delete WordPress Post Revision From Database

The following snippet will let you delete WordPress post revision from the database.

Snippet Source/Credit: lesterchan.net

How To Display Recent Posts From All Sites

The following snippet will display recent posts from all sites.

Snippet Source/Credit: Snipplr

The Snippets Collection – 4

WordPress-Media-Upload

How To Automatically Add Post Name To The Body Class

The following snippet will let you automatically add post name to the body class.

Snippet source/Credit: WPProgrammer.com

How To Add An Extra Contact Methods To User Profiles

The following snippet will let you add an extra contact methods to user profiles.

Snippet Source/Credit: TutsPlus

How to change WordPress editor font

Using the following snippet, you will be able to change WordPress editor font.

Snippet Source/Credit: DevPress

How To Automatically Obfuscate Email Addresses

The following snippet will let you automatically obfuscate email addresses.

Snippet Source/Credit: WordPress Codex

How To Disable Plugins Update In WordPress

The following snippet will let you disable plugins update in WordPress.

Snippet Source/Credit: WP Snippets

The Snippets Collection – 3

WordPress

How To Load All Posts From The Current Week

Using the following snippet, you will be able to load all posts from the current week.

Source Snippet/Code: Christian Brückner

How To Remove Widgets From WordPress Dashboard

Using the following snippet, you will be able to remove widgets from WordPress dashboard.

Snippet Source/Credit: WP Guru

How To Add A Custom Message To The Editor Pane

Using the following snippet, you will be able to add a custom message to the editor pane.

Snippet Source/Credit: WP Tuts

How To Limit Posts Per Page On Search

The following snippet will let you limit posts per page on search.

Snippet Source/Credit: WordPress.org

How To Log-in A WordPress User Programmatically

The following snippet will let you log-in a WordPress user programmatically.

Once done, now to log-in a user, just simply do the following:

Snippet Source/Credit: emoticode

Snippets Collection Part – 5

Programming-1

How To Display A Thumbnail Of Any Website

Using the following snippet, you will be able to display a thumbnail of any website.

Once done, you can use the snap shortcode:

Snippet Source/Credit: Greekeries.fr

How To Automatically notify your members on new posts

Using the following snippet, you will be able to automatically notify your members on new posts.

Snippet Source/Credit: WordPress Codex

How To Display A Thumbnail From A YouTube Video Using A shortcode

Using the following snippet, you will be able to display a thumbnail from a YouTube video using a shortcode.

Snippet Source/Credit: Gunay

How To Automatically Add Post Name To The Body Class

Add the following snippet in your theme’s functions.php file, you will be able to automatically add post name to the body class.

Snippet source/Credit: WPProgrammer.com

How To Add An Extra Contact Methods To User Profiles

Using the following snippet, you will be able to add an extra contact methods to user profiles.

Snippet Source/Credit: TutsPlus

How To Automatically Prefetch Next Pages On Your WordPress Blog

Using the following snippet will let you automatically prefetch next pages on your WordPress blog. All you have to do is to simply paste the snippet in your theme’s header.php file and you are done.

Snippet Source/Credit: Bernd

The Snippets Collection – 2

WordPress

How To Load jQuery From Google CDN

WordPress by default load its own jQuery in your theme BUT using the following snippet in your theme’s functions.php file will load the library directly from Google CDN.

Snippet Source/Credit: WP Tips

Adding Paragraph Tags Automatically In Your WordPress Blog

Using the following snippet, you will be able to add paragraph tags automatically in your WordPress blog.

Snippet Source/Credit: Daniel Pataki

Changing Author URL Base

The following snippet will let you change author URL base.

Snippet Source/Credit: Kevin Chard

How To Redirect To A Custom Page After Registration

The following snippet will let you redirect to a custom page once registration got completed. Simply copy the snippet and paste it to your theme’s functions.php file.

Snippet Source/Credit: TheDeadMedic

Changing WordPress Login Logo Title Attribute

Using the following snippet, you will be able to change WordPress login logo title attribute.

Snippet Source/Credit: Dave Clements

The Snippets Collection – 1

wordpress-logo

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 Automatically Add Twitter And Facebook Buttons To Your Posts

Using the following snippet, you will be able to automatically add both Twitter and Facebook buttons to your posts.

Snippet Source/Credit: WPRecipes

How To Get The First Link In Post

Using the following snippet and pasting it in your theme’s functions.php file will let you grab the first link in the post.

Snippet Source/Credit: Filip Stefansson

How To Get Email Alerts For 404 Pages In WordPress

Using the following snippet, you will be able to get email alerts for 404 pages in WordPress.

Snippet Source/Credit: WP Mix

How To Display Recently Registered Users

Using the following snippet, you will be able to display recently registered users.

Snippet Source/Credit: emoticode

Snippets Collection Part – 4

Programming-7

How To Limit Posts Per Page On Search

Using the following snippet, you will be able to limit posts per page on search.

Snippet Source/Credit: WordPress.org

How To Display The Number Of Results In WordPress Search

Using the following snippet, you will be able to display the number of results in WordPress search.

Now, simply replace it with to:

Snippet Source/Credit: ProBlogDesign

How To Log-in A WordPress User Programmatically

Using the following snippet, you will be able to log-in a WordPress user programmatically.

Once done, now to log-in a user, just simply do the following:

Snippet Source/Credit: emoticode

How To Create A Pinterest ‘Pin It’ Button For Your Blog

Using the following snippet, you will be able to create a Pinterest “Pin It” button for your blog.

Once done, open your footer.php file and add the Pinterest JavaScript code:

Snippet source/Credit: MarketingTechBlog

Snippets Collection Part – 3

Programming-3

How To Change WordPress Login Logo Title Attribute

Using the following snippet, you will be able to change WordPress login logo title attribute.

Snippet Source/Credit: Dave Clements

How To Load All Posts From The Current Week

Using the following snippet, you will be able to load all posts from the current week.

Source Snippet/Code: Christian Brückner

How To Add A Custom Message To The Editor Pane

Using the following snippet, you will be able to add a custom message to the editor pane.

Snippet Source/Credit: WP Tuts

How To Remove Widgets From WordPress Dashboard

Using the following snippet, you will be able to remove widgets from WordPress dashboard.

Snippet Source/Credit: WP Guru

How To Delete WordPress Post Revisions Using Your Functions.php File

Using the following snippet, you will be able to delete WordPress post revision using your functions.php file.

Snippet Source/Credit: Hardeep Asrani

How To Add A Link To Your Post Using RSS Feed

Using the following snippet, you will be able to add a link to your post using RSS feed.

Snippet Source/Credit: Yoast

Snippets Collection Part – 2

Programming-2

How To Add A Google+ Button To Your Posts

Using the following snippet, you will be able to add a Google+ button to your posts.

Snippet Source/Credit: SpyResStudios

How To Add Gravatars For The Post Author

Using the following snippet, you will be able to add Gravatars for the post author.

Snippet Source/Credit: emoticode

How To Change Author URL Base

Using the following snippet, you will be able to change author URL base.

Snippet Source/Credit: Kevin Chard

How To Redirect To A Custom Page After Registration

Using the following snippet, you will be able to redirect to a custom page after registration.

Snippet Source/Credit: TheDeadMedic

Snippets Collection Part – 1

Programming-4

How To Completely Shut Down WordPress Search

Using the following snippet, you will be able to shut down WordPress search completely.

Snippet Source/Credit: WPEngineer

How To Enlight Searched Text In Search Results

Using the following snippet, you will be able to enlight searched text in search results.

And now just before the line you modified, add this code of lines:

Once done, now open style.css and append the following line to it:

Snippet Source/Credit: Yoast

How To Automatically Add Facebook Open Graph To Your Posts

Adding the following snippet in your WordPress theme’s functions file, you will be automatically able to add Facebook open graph to your posts.

Once done, now open your header.php and replace the <html> tag with:

Snippet Source/Credit: WP Tutsplus

How To Redirect To First Post If Only One Post Is Found

Using the following snippet, you will be able to redirect to first post if only one post is found.

Snippet Source/Credit: Paulund.co.uk

How To Make Your WordPress Website SEO Friendly Without A Plugin

Using the following snippet, you will be able to make your WordPress website SEO friendly without a plugin.

Once done, simply replace the $default_keywords in line 3 with your own keywords and add the following line of code into your theme’s header.php file.

Snippet Source/Credit: Jeff Starr

Page 3 of 12

Powered by WordPress & Theme by Anders Norén