Category Archive: WordPress
Posts about WordPress
This technique is a bit esoteric and mostly for my own reference. Feel free to try the code if it makes sense to you; otherwise, maybe just move on to the next code snippet. Just not enough time in the day to explain everything.
This tutorial explains how to get the current Post Author outside of the WordPress Loop.
This WordPress snippet disables all author-archive views. This may be useful to prevent user enumeration scans, and also may help to minimize duplicate content (for SEO purposes).
In this tutorial, you’ll learn two ways to get the most recent comments on your WordPress-powered site. The first method uses get_comments(),and the second method uses the newer WP_Comment_Query class.
This tutorial provides four techniques for linking WordPress attachment pages back to their parent posts. Adding such a link makes it easy for users to view an image or other attachment, and then quickly navigate back to the original gallery in the parent post.
The readme.txt file plays a central role when developing WordPress plugins, especially when hosting them at the WordPress.org Plugin Directory. In this post I share some esoteric readme.txt tricks that plugin and theme developers may find useful.
Here are some sweet code snippets for getting various types of server information. Includes more functions for getting and/or checking various types of WordPress, PHP, and SQL data. Strictly plug-&-play for quick reference and copy/paste usage.
Some quick copy/paste snippets taken from my dev/test theme, Introspection. Posting them here for reference so I can grab ’em as needed.
This tutorial explains how to hook up automatic clearing of chat messages with my WordPress plugin, Simple Ajax Chat.
Some servers disable the functionality that enables WordPress Cron to work properly. This post provides an easy fix that should work on any server.
Here are some notes to help discern the subtle (and oft-confusing) differences between the WordPress functions, home_url and site_url (and their related “get” functions, get_home_url and get_site_url). We’ll look at the output of these functions and how they relate to the WordPress General Settings.
Here is a function that I use in my plugin, Dashboard Widgets Suite. It provides a sane, practical set of HTML tags and attributes for WP’s wp_kses family of functions.