While writing my previous article on creating the perfect WordPress title tags, I deliberately avoided discussing the use of separators in titles. I feel that the topic is worthy of its own article, enabling a more thorough exploration of the details. Title separators are the symbols, punctuation, and other characters used to distinguish between various parts of the page title. For example, a title may include the blog name, post title and blog description, with each element separated by a hyphen. Any Google search will reveal that some of the most commonly used title separators include the hyphen, the dash, and angled quotes. Many others are used as well, and we will explore some of them in this article.
Continue Reading
Note: This information is intended primarily for WordPress versions previous to 2.3, but may be applicable in other versions as well.
For those of you running an older version of WordPress that is generating errors such as:
Warning: parse_url(http://) [function.parse-url]: Unable to parse url in /home/path/to/public_html/wordpress/wp-includes/functions.php on line 1067
Warning: parse_url(http://) [function.parse-url]: Unable to parse url in /home/path/to/public_html/wordpress/wp-includes/functions.php on line 1067
Warning: parse_url(http://) [function.parse-url]: Unable to parse url in /home/path/to/public_html/wordpress/wp-includes/functions.php on line 1067
Warning: parse_url(http://) [function.parse-url]: Unable to parse url in /home/path/to/public_html/wordpress/wp-includes/functions.php on line 1067
Warning: parse_url(http://) [function.parse-url]: Unable to parse url in /home/path/to/public_html/wordpress/wp-includes/functions.php on line 1067
Warning: parse_url(http://) [function.parse-url]: Unable to parse url in /home/path/to/public_html/wordpress/wp-includes/functions.php on line 1067
Warning: parse_url(http://) [function.parse-url]: Unable to parse url in /home/path/to/public_html/wordpress/wp-includes/functions.php on line 1067
Warning: parse_url(http://) [function.parse-url]: Unable to parse url in /home/path/to/public_html/wordpress/wp-includes/functions.php on line 1067
You can easily resolve the issue by suppressing these errors, which are automatically generated whenever the parse_url() function tries to parse an empty value for the URL. To silence the errors, open the file wp-includes/functions.php and locate the following code (around line #1067):
Continue Reading
After much deliberation, I have decided to take a short vacation away from the computer. I have been working like a dog recently, and feel that a change of pace would help recharge the ‘ol brain cells. I haven’t decided exactly when it will be, but I am thinking that some time off in August (my favorite month) would be swell. Maybe go to the coast, do some traveling, take a long nap, or whatever. Technically, I haven’t taken a break from blogging here at Perishable Press in almost three years! So it’s definitely time..
Generally, I like to post three or four times a week, depending on my schedule. As most of you know, I like to post quality articles on just about anything related to Web development, graphic design, blogging, social media, SEO, site security, and just about anything related to technology, creativity, and design. Given a two-week hiatus, I am asking for help with around seven or eight guest posts, preferably from a few different authors.
Continue Reading
![Firefox Keyboard Shortcuts [ Macintosh Keyboard ]](http://perishablepress.com/press/wp-content/images/2008/fx-shortcuts/fx-shortcuts_01.jpg)
As my browser of choice, Firefox provides all the functionality I need for web design, application development, everyday surfing, and much more. With a handful of choice extensions installed, Firefox is a lean, mean “get-it-done” machine. Plus, I am always looking for new ways to boost productivity and increase efficiency. Of course, an excellent way to do this involves learning and using as many mouse and keyboard shortcuts as possible. Over the past few years, I have collected oodles of shortcut snippets for Firefox. Thus, in an effort to purge my constantly growing stash of notes, I decided to round up all of the Firefox shortcuts I could find, clean them up a bit, and post the collection online for everyone to enjoy. Drum roll please: now presenting 85 Firefox Shortcuts for Mac and PC! Enjoy..
Continue Reading
In an effort to organize my pile of offline notes, I will be posting a number of quick, “to-the-point” tutorials on a number of useful topics. In this post, I share an excellent method for auto-clearing and restoring multiple form field inputs using a bit of unobtrusive JavaScript. This method was discovered at xy.wz.cz. There are two steps to this technique, which should take no longer than five minutes to implement.
Continue Reading
Keeping an eye on all things WordPress, I have noticed an ongoing fascination with configuring the ultimate WordPress <title> tags. Many bloggers use various plugins to generate differently configured <title> tags depending on particular page views. A good example of this is seen in the All in One SEO Pack, which, among many other things, enables users to specify custom titles for several different types of pages. While there is nothing wrong with this approach, some of us prefer to run WordPress with as few plugins as possible. If you want to create perfect WordPress title tags without a plugin, this post will certainly help you do it. First we’ll explore some of the basics, continue with some common examples, and then conclude with a comprehensive, highly flexible script for generating distinct page titles. All of the techniques presented in this article should work well with virtually all versions of WordPress.
The Basics
The <title> tag is used within the <head> section of (X)HTML pages to communicate the title of the document to both humans (your visitors) and machines (search engines). For dynamically generated sites, such as those powered by WordPress, many different types of pages exist, including:
Continue Reading
This was just too juicy to pass up. Blogstorm recently blogged about an easy JavaScript technique for making any website editable. After checking it out for myself, I just had to share it here at Perishable Press. Here it is:
javascript:document.body.contentEditable='true'; document.designMode='on'; void 0
Paste that single line of code into the address bar of any modern browser and have fun editing the page. Obviously, any changes will only apply to the page as seen in your browser, not the original document. Even so, it’s a fun trick to play around with, snap screenshots, be creative, etc.
Go ahead — amaze your friends!
Continuing the CSS Hackz Series, I present a small army of hacks for targeting and filtering Internet Explorer 7! Here, “targeting” IE 7 means to deliver CSS and/or (X)HTML to IE 7 only, while “filtering” means to deliver CSS and/or (X)HTML to every browser that is not IE 7. In other words, targeting is to include (apply), filtering is to exclude (hide). Let’s dive right in..
Conditional Comments
Conditional comments are a proprietary Microsoft technique for targeting and filtering different versions of Internet Explorer. Other browsers do not understand them, and will treat them as regular (X)HTML comments. Of all the techniques presented in this article, conditional comments are perhaps the most flexible method for targeting and filtering any version of Internet Explorer, including IE 7. Here are some self-explanatory examples:
Continue Reading
After almost three years of blogging here at Perishable Press, I had an epiphany about my author comment links. Way back when, after installing WordPress in a subdirectory called “/press/”, I decided to set the URL for my Administrative User Profile’s website as “http://perishablepress.com/press/”. After all, it seemed to make sense at the time, plus it really didn’t seem to matter; nobody was going to see my personal profile information anyway, right?
Wrong.
Three years later, I finally realize that it does matter. The URL that you enter as your profile’s website address is the URL that will be used for every author commentator link on your site. Yes, I know what you’re probably thinking, “what an idiot! I thought everybody knew that!” Well, no, obviously not everybody. It may have occurred to me momentarily or subconsciously at some point along the way, but it wasn’t until just a few days ago that the light bulb finally flashed.
So what’s the big deal? First and foremost, one of the most highly visible and prevalent links to your site comes from your own author commentator links. These links are used to represent your site for every one of your own comments. Other commentators and visitors recognize the link, note the location, and possibly use it when linking back to your site. Thus, it is important to represent your site by linking to the optimal URL in your author commentator links.
Continue Reading
When frustration builds, and finally reaches its the boiling point, it’s nice to be able to express yourself to someone. Although I really don’t enjoy ranting about things, but when it comes to certain aspects of Yahoo!, I just can’t he’p myse’f. So, thanks to recent attempt at using My Yahoo!, it’s time to get some of this off my chest, clear the decks, and give Yahoo! (yet another) chance to clean up its act. Here are a few complaints I have against various aspects of the Yahoo! enterprise..
First and foremost, Yahoo! sends virtually zero traffic. I know this sounds painfully selfish, but I don’t understand why the top-ranking search engine finds Perishable Press worthy of around 2000 referrals per day, but Yahoo! can’t seem to justify more than a few each week. I mean come on, even good ‘ol MSN/Live manages to send a few hundred uniques per month 1.
So that sucks, and honestly doesn’t win Yahoo! any golden biscuits from me, not that it needs them. But perhaps more relevant and disturbing is Yahoo!’s relentless army of Slurp bots. I have never seen so much unusual, unexpected, and unwanted crawl behavior from any other legitimate search-engine robot. Seriously, some of the URL requests recorded in my arsenal of Web and error logs are like from another planet or something. Where are they coming up with some of this stuff:
Continue Reading
Recently, I received a bizarre email accusing me of calling someone out on their fake Feedburner subscriber count. Apparently, some desperate blogger had been claiming to have something like 30,000 Feedburner subscribers when in reality they only had around 700. From what I could tell, the fraudulent site was displaying a counterfeit Feedburner subscriber-count badge using some fancy CSS image-replacement or something. Whatever. I really could care less, but the information contained in the email got me thinking:
Providing an easy way for visitors to verify your subscriber count is a good idea..
Enabling visitors to quickly and easily verify your claimed subscriber count fosters a sense of credibility and legitimacy concerning you and your site. Especially for larger feed counts, validating your claim removes doubt, improves perception, and solidifies reputation. Without some sort of verification, new visitors to your site have no practical way of determining the validity of your claim. Reassuring your guests with an official “verification” link is an excellent way to demonstrate your authenticity and sincerity. Users may or may not actually click on the link, but its mere presence provides a clear signal of your site’s integrity. You know, like saying “look, this is the real McCoy — I’m not faking popularity for personal gain.”
Continue Reading
Just a quick WordPress snippet for future reference. I recently explained how to disable comments, pingbacks, and trackbacks via SQL. Here’s a good way to do it via PHP:
<?php
function close_comments( $posts ) {
if ( !is_single() ) { return $posts; }
if ( time() - strtotime( $posts[0]->post_date_gmt ) > ( 30 * 24 * 60 * 60 ) ) {
$posts[0]->comment_status = 'closed';
$posts[0]->ping_status = 'closed';
}
return $posts;
}
add_filter( 'the_posts', 'close_comments' );
?>
You can run this script as a plugin, through your theme’s functions.php, or through a custom user-functions.php file. Simply set the desired number of days by changing the number “30” to whatever you would like. As is, this script will close comments, pingbacks and trackbacks on all articles posted more than 30 days ago.
As you may observe, the WordPress installation that powers Perishable Press is located in a subdirectory named press. This configuration was intentional, as I wanted to have the option to easily install and maintain multiple versions of WordPress in variously named subdirectories. As much as I enjoy this flexibility, many would argue the SEO-related benefits of installing WordPress in your site’s root directory, or at least making it appear that way by using WordPress’ easily customizable “Blog Address” options setting.
For example, say you have WordPress installed in a subdirectory called “gibbonz”, but you want your blog’s home page to exist at http://your-domain.tld/ and not http://your-domain.tld/gibbonz, as would be the case by default. To make this happen, you have several choices, including this method, which I summarize here, assuming the “gibbonz” scenario outlined in the preceding discussion:
Continue Reading
One of my favorite aspects of producing clean, well-formatted CSS code is “meta-organizing” the document using comments. In CSS, comments are included in the stylesheet like so:
/* i am the walrus */
When used constructively, CSS comments serve to break down documents into distinct regions, provide key information about specific declarations, and bring order to even the most complex stylesheets. In my experience, a well-commented stylesheet improves efficiency and optimizes comprehension.
Working with CSS, you can add comments any way you want. There are many different ways to use CSS comments, and endless ways to get there. Let’s check out some practical and interesting ways to use comments, along with some creative ways of doing so.
Continue Reading
I recently twittered my intention to switch from the Firefox browser to the sleek, new Opera 9.5. I have always used Opera as a secondary browser, especially handy for speedy jumps into cyberspace, browser testing, and taking up space on my hard drive. I have always wanted to switch completely to Opera, but for many reasons, Firefox just keeps pulling me back into its comfortable grasp..
After a quick Opera-9.5 download, I decided to install Opera in its own directory instead of upgrading my current 9-point-whatever version. Unlike some browsers, multiple installations of Opera require nothing more than separate directories (as specified during the setup process). Within moments Opera 9.5 was loaded up and running tuf. The new darker default interface is sleek and sexy, inspiring me all the more to continue my quest to switch from Firefox.
As I began configuring the new Opera with imported bookmarks, speed-dial, home-page settings, and tab groups, I found myself digging up passwords that I haven’t had to remember in years. I know that Opera is equipped with its own “Remember Password” functionality, but you still have to enter each password at least once in order for it to work. Not a big deal, and certainly nothing against Opera, but it would have been great to have been able to import all of my saved Firefox passwords (if that’s even possible). In any case, after loading up and logging in to my core collection of tabbed sites, I spent a majority of the day using Opera instead of Firefox for all of my design, admin, and surfing needs.
Continue Reading