Like the blog? Get the book »

Posts tagged: tricks

Archive page 4 of 6
Secure uploads, upgrade and other directories with .htaccess

Secure uploads, upgrade and other directories with .htaccess

It sucks, but a lot of plugins require certain directories to be set at CHMOD 777 for its file permissions. Of course, you should not use any plugin that requires 777 directories, but if you absolutely must, you can help protect the folder by adding a thin slice of htaccess. This works great for any directory requiring “loose-ish” permissions (i.e., anything greater than 755), and may also be useful for other key folders as well.

WordPress Admin Bar Tricks

WordPress Admin Bar Tricks

According to our latest poll, so far the votes are pretty much split on whether people love, hate, or don’t care about WordPress’ new Admin Bar. Over time, it looks like “Hate it” has started to pull ahead, but it doesn’t matter because the Admin Bar Toolbar is here to stay, regardless of opinion. Already there are many awesome ways to make it do virtually whatever you want. So that’s the deal, and in this DigWP post, we round up a ton of tips, tricks, and plugins for ultimately mastering the WordPress Admin Bar.

What to do when WordPress Auto-Update Fails

What to do when WordPress Auto-Update Fails

Ahh yeah, WordPress just rolled out another update to version 3.1.1. If you’re able to upgrade via the Admin, updating your site(s) should be a piece of cake: just log in, click a few buttons, wait a few minutes, and done. The convenience of automatically updating the WordPress core, plugins, and themes is awesome, but things can go wrong once in awhile and auto-updates can fail.

If this happens, getting back on track is a bit tricky, so here’s a quick guide to help restore site functionality and ensure a proper WordPress update.

Display Total Number of Blogroll Bookmarks

Display Total Number of Blogroll Bookmarks

Quick WordPress tip for you today! A reader recently asked about displaying the total number of blogroll bookmarks on their site. This sounds simple enough but not everyone meddles with code these days, so here is a nice PHP snippet that will do the job. You can add this code anywhere in your theme template (wherever you want to display the total number of Blogroll links).

Speed Up Your Blogging with WordPress Shortcodes

Speed Up Your Blogging with WordPress Shortcodes

Shortcodes are WordPress’ way of creating shortcuts for code snippets, strings of text, or anything else that you need to display on your site. So this means that you can save time by replacing your most commonly typed words and phrases with WordPress shortcodes. For example, if you are frequently typing your blog’s URL, you could place the following code your theme’s functions.php:

Easy Comment Management via SQL Queries

Easy Comment Management via SQL Queries

Here are some sweet SQL code snippets for easy comment management. Sometimes it’s easier to modify comment status and delete unwanted comments on a sitewide basis. Using a program like phpMyAdmin makes it so easy to do stuff like remove spam, close/open comments on old posts, enable/disable pingbacks for specific time periods, and so on. Just remember to backup your database before running any queries (just to be on the safe side).

Show Post Thumbnails in Feeds

Show Post Thumbnails in Feeds

One of the nice things about using WordPress’ new post-thumbnails feature is that they provide tons of flexibility in terms of where and how you display your post thumbnails. By design, post thumbnails are not included within post content, so they will not be displayed in your blog posts unless you call them specifically with the proper template tag:

Add Private Content to Posts via Shortcode

Add Private Content to Posts via Shortcode

Recently, WP-Mix posted an incredibly useful technique that uses a shortcode to add private content to blog posts. This functionality makes it easy to manage leftover data, miscellaneous notes and other communication by keeping everything together with its corresponding post. Consolidating information like this helps to streamline flow and organization into the future.

Next/Previous Post Navigation Outside of the WordPress Loop

Next/Previous Post Navigation Outside of the WordPress Loop

WordPress provides several navigational template tags to make it easy for visitors to surf your pages. There are basically two different types of template tags used for chronological post navigation:

Remove/Replace Content from the WordPress Database

Remove/Replace Content from the WordPress Database

A useful tool to have in in your WordPress toolbelt is the ability to quickly and easily search for, find, and replace specific strings of text directly from the MySQL database. We can do this by entering SQL queries either directly or through one of those handy interface applications like phpMyAdmin, which seems like one of the most prevalent PHP applications on servers today.

Change Quick Action Button in Admin

Change Quick Action Button in Admin

You know the “quick action” button in the WordPress admin? It’s a darn useful little UI touch. At the Dashboard, the default is “New Post”. But depending on where you are in the Admin, the default of it changes. In general it’s really helpful. For example when you are in the Plugins area, the default is Install Plugins:

Display Separate Counts for Comments, Pingbacks and Trackbacks

Display Separate Counts for Comments, Pingbacks and Trackbacks

In WordPress, there are three ways to respond to a post: you can leave a comment, leave a trackback, or just link to the post to create a pingback. When displaying all of the responses to your posts, it’s a good idea to separate the comments from the pingbacks and trackbacks. Uninterrupted comment threads are a pleasure to read, as are well-styled lists of pingbacks. This is an excellent way to improve the usability and stylishness of your comment areas.

WordPress Tip: Remove nofollow Attributes from Post Content

WordPress Tip: Remove nofollow Attributes from Post Content

If you have posts that include the nofollow attribute on links, you may at some point decide to remove them. By default, WordPress doesn’t insert nofollow attributes in post content, but there are a variety of plugins that will insert nofollow into all links in post content.

Or perhaps you have been manually adding nofollow tags to your post links for SEO purposes. Regardless of how they got there, it’s very easy to clean things up and remove all nofollow attributes from post content.

Include the Category ID via post_class

Include the Category ID via post_class

The default output for WordPress’ post_class template tag includes class names for just about every type of page view imaginable:

© 2009–2024 Digging Into WordPress Powered by WordPress Monzilla Media shapeSpace