Popular Posts
All posts ordered by popularity
Redirect HTTP to PHP via .htaccess
Here is how to redirect specific URL requests to a PHP script for further processing, etc. Very useful for monitoring HTTP activity, logging errors, and more.
Cross domain posting with Ajax
Technically cross-domain posting is not allowed, but here is a workaround that may prove useful for your brainstorming sessions. Note that this technique is aimed at advanced developers.
Auto-Focus Form Fields with jQuery
When you load a page that contains a form, it may be useful to automatically place the user’s cursor in the first form field. This post explains how to do autofocus with jQuery.
WordPress enqueue user-agent stylesheets
WordPress makes it clean and easy to enqueue custom stylesheets via the functions.php file. Here’s how to do it for user-agent stylesheets.
Force file download with .htaccess
Here is a quick .htaccess snippet that will force files to download instead of displaying in the browser. This method works for any site running on an Apache server.
Google Translate in 2 Steps
Follow this simple two-step tutorial to enable users to translate your web pages into many different languages. Great way to increase exposure and traffic.
Get all meta data for WordPress user
Quick tip to get all meta data for any WordPress user. Warning, arrays ahead..
WordPress Disable jQuery Migrate
The jQuery Migrate plugin is used to help sites upgrade to the latest version of jQuery. The script restores APIs that have been removed, and the development version shows warnings in the browser console for any deprecated or missing APIs. This enables developers and admins to more easily upgrade from older to newer versions of […]
WordPress Disable Author Archives
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).
Shortcut to WP Login
Back in January of 2011, Chris Coyier posted a sweet .htaccess technique for setting up Simpler Login URLs in WordPress. This is a follow-up technique that’s slightly improved..
WordPress redirect logged in users
Nice WordPress snippet to redirect logged in users to any location. Also optionally redirect visitors who are not logged in to WordPress.
jQuery Reload Current Page on Click
jQuery makes it easy to do all kinds of cool stuff. For example, here is a code snippet to reload the current page with a click.