Category Archive: WordPress
Posts about WordPress
WordPress Create New User
Two ways to programmatically create new users in WordPress. The first method uses wp_create_user() and the second method uses wp_insert_user().
Filter pre tags in bbPress
A couple of functions used at htaccessbook.com to enable unescaped/unencoded pre and code tags in bbPress forum posts.
Display a Simple “Tweet This” Link
Twitter changes their API quite a bit, however it is still possible to display a simple “tweet this” link anywhere on your web pages.
WordPress Create Shortcode
Ultra-quick guide to help you create a WordPress Shortcode. Aimed at experienced WordPress users who need a basic example of how to create shortcodes.
WordPress Check PHP Version
When working with the WP API, you may need to check the current version of PHP to ensure compatibility.
Dealing with translation spam
How I respond to “translation spam”, which happens when greasy organizations ask permission to translate your script, extension, plugin, etc.
WordPress Set Featured Image with Fallback
In this tutorial, we’ll see how to enable theme support for Featured Images (aka Post Thumbnails), and also how to display them with fallback image support.
WordPress Do Stuff on First User Login
Here is a code snippet that runs the first time a user logs in to their registered account. Useful for sending custom welcome emails, or whatever.
WordPress Create Upload Files and Directories
This tutorial explains how to create new files and directories in the WordPress /uploads/ folder.
WordPress Allow HTML in Author Bio
By default, WordPress filters out any markup included in the description (bio) of user profiles. Here is a code snippet to allow HTML in author bios.
WordPress Check User Roles
Here is a plug-n-play function to check user roles, based on an array of input values.
WordPress wp-config.php tricks
A concise collection of wp-config.php tricks from my WordPress sites to yours.