10 undeniable, unspoken truths about blogging

(Reading time: 7 – 12 minutes)

Having just about bounced back from a particularly tardy finish on the blogging front, I’m probably in a great place, yet terrible time to uncover the truth about blogging.

I just found that there are 15 million blogs on the web. Now there are 15.2m. By the time you read this there will be more blogs than phones and people combined. Here and on Mars.

Having a burning desire to learn from as many people as possible, I’m quite frustrated that I might never be able to get round all these blogs. But this can only be a good thing. Not everyone has something valuable to say. And God forbid, there may be other sites out there like this one, and like me you might prefer to experiment with sticking hot pins in your eyes rather than risk another error of judgement.

I only wish when I started at the University of Blognor in Wales (well it exists in my head) I knew the stuff I know now. I might have chosen cookery instead.

See, when it comes to blogs, they don’t say:

1. The clock moves faster

I swear it wasn’t 4.30am when I finally nipped and tucked this blasted site into submission. I had undergone hair-stripping angst at the categoric failure to fix my broken comments system. The problem resulted from my lack of focus on the intricacies of point 5. If you take pride in the content you manufacture, then the chances are the time will fly at a speed exceeding Richard Branson’s spaceship. To entertain and captivate you I underwent years of training at newspapers, magazines and websites. I don’t believe the journey of education ever ends, but I did (falsely) believe that after nearly 15 years of writing this blog stuff would consist of a lightningly-quick post every day. In reality, we’re talking at least an hour every time. That’s an hour of my working day devoted specifically to you. I can’t start any earlier, because Princess loves snuggles and won’t sacrifice any of them for your eyes. Start a campaign.

2. Care? Code!

When I started this journey I was defiant – I’d have the skills I needed to captain a blog because, hell, I could write. And that’s what blogging is about, right? Well, wrong. If you have ideas above your station and want to get yourself a fully customised web presence, you can’t just rely on a free theme and a tickled ego. There’s CSS to learn, PHP to give you suicidal tendencies. Thankfully the web is replete with all sorts of funky things to help you step closer to madness.W3Schools has a great ‘spaz’ PHP tutorial list, echoecho can sort out your CSS catastrophes while lynda.com has fantastic video series devoted to both quirky ways to roll. And when you have questions? Try the excellent forums at SitePoint and WebmasterWorld

3. Making money is harder than impossible

This is a dark art as garbled as SEO right now. I’m sick to the core of people churning out self-serving ‘ways to make $$$’ eBooks. Actually that’s only a half-truth. If the eBooks work, then they are better than beer. But most don’t, believe me. The first thing you need to do is buy the OIO Publisher plugin which is just the most amazing way to manage and serve up adverts ever. If I can do it, believe me, you can do it with ease. The support and tutorials are superb and they even just launched a ‘wizard’ to install the plugin direct to your site (WordPress or otherwise) from the OIO website. Having said that, there’s some chap who puts out an absolutely genius ebook about why…

4. Pillar content rules!

It took me five years to get it.

To understand how you become a respected member of the electro-chattyverse. You write a single post or series of features devoted to removing someone else’s problem. It could be your problem. But if you document it and hit the nail on the head by scratching the itch, you have friends for life. My favourite pillar content creator du jour is David Doolin, aka Dr WordPress. Through experience and straightforward genius he saw there were still people in the world who wanted to set up a blog. So to those nine people (eight… seven…) David said: “Look – give me a weekend, and I’ll give you a blog. A bloody amazing blog!” And he pulls it off in such an entertaining and educational way, that even blog regularists will learn something from his wise 2.5 day tutelage. Start here.

And while you’re here, why not take up David to personally building your website over a weekend for just $300 – with every penny going to relief efforts for Haiti. [This offer is expired! But watch this space. -Ed.]

5. .htaccess matters

It matters so much it chewed six hours out of my Saturday night. That raised the hackles, let me tell you. I had no idea I had a .htaccess in the root of my server space which was reigning roughshod across my other blog sites. It meant my comments system was redirecting to a non-existent page. 404-tastic! It caused me a marathon head fug to not understand the true might of this security-driven file. It drove me mad. It drove my web host mad. But we got there.

The difference between needing to know .htaccess at a basic level is the difference between hosts. I didn’t really need to know much at fatcow, but with clook, which is a really nice web host with the best support imaginable, it mattered. Check out Josiah Cole’s ‘almost-perfect .htaccess file‘ for WordPress and change all the yourdomainhere.com elements to, well, your domain name before uploading it to the root of your blog site. And check out more about .htaccess and the power it wields over everything you blog.

6. Plugins are inherently evil

They make things slow. There are exceptions like WP Super Cache and Headspace2 SEO and the Google Analytics for WordPress plugins but in most cases these days either WordPress has filled in the gaps the plugins plugged, or you can fix some code with the limitless guidance on WordPress hacks from the likes of Jeffro’s WP TavernDigging Into WordPress and Marko Saric’s How To Make My Blog.

7. Permissions

Permissions can mess your site up royally. They’re either impassable sentinels or free-for-all and there seems very little middle ground. One thing you need to know is how to change them when you suddenly come up against a brick wall. Make absolutely sure your code isn’t at fault then dive in to the Permissions on an individual file level, before changing the Permissions of an entire folder. You do this in FileZilla (my FTP client of choice) by right-clicking on the file and selecting Permissions. If what you’re doing is blocked, go for 755 and if not, 777 (but unless absolutely necessary, restore its previous Permissions because leaving the gate widen open – as 777 does – can be a security issue).

8. You gotta write like a literary ninja

I’ve decided to banish all evil scribbling from the web. I’m hoping this will be a crowdsourcing strategy. I may use that Mechanical Turk website but I’m thinking it would probably cost Barack Obama’s annual salary alone just to get rid of the spelling mistakes from websites operated by bed and breakfast joints.

Since my pockets are not bottomless I have decided to adopt a slightly different tactic. I will be helping everyone around me to write better instead. Watch this space

9. You need a book

You have four options: The WordPress Bible, Digging Into WordPressHow To Be A Rockstar WordPress Designer and the frankly now-outdated WordPress 2.7 Cookbook. Let’s roll with it: Digging for code, Rockstar for design, Cookbook for a smorgasbord of everything. Like a finger buffet with chicken and mushroom Toast Toppers vol-au-vents. Don’t lie – you love ‘em too!

Check out frameworks!

It’s the future for everyone. There – I said it. Frameworks are the skeletons upon which you mould the flesh of your site. So you start with an impermeable (but basic-looking) foundation with all the code you need, then using CSS and a bit of PHP (realistically, as much as you feel comfortable with) craft your own unique blog site. Thematic is incredible. Hybrid – a Justin Tadlock production – shows incredible potential and he’s even dispensing solid insinuations he may soon be working on a model not dissimilar to the ‘tailor your own home page shifting blocks about’ concept first employed at the BBC website. Focus on these. There are others, but for invaluable support you can’t go wrong.


Dave Thackeray Want to be a radio star? Guest on Dave Thackeray's InspiRadio, a unique business-focused online radio network. Listen live or check out the InspiRadio website for more information.

Dealing With PHP Memory Issues For Self-Hosted WordPress Blogs

(Reading time: 5 – 8 minutes)

Once you’ve installed a few blogs, you are going to run up against a PHP “out-of-memory” error.

They look something like this:

[02-Jul-2009 22:41:54] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 7680 bytes) in /home2/equalit6/public_html/wp-includes/kses.php(1005) : runtime-created function on line 1

This php memory error is usually not too difficult to fix…

Fixing your locally hosted WordPress installation

If you’re running your own, personal PHP installation, it’s really simple: open up your php.ini file, increase the allowable memory limit. For example, here’s what it looks like in my localhost php.ini:

300
301
302
303
304
305
306
307
;;;;;;;;;;;;;;;;;;;
; Resource Limits ;
;;;;;;;;;;;;;;;;;;;
 
max_execution_time = 30     ; Maximum execution time of each script, in seconds
max_input_time = 60	; Maximum amount of time each script may spend parsing request data
;max_input_nesting_level = 64 ; Maximum input variable nesting level
memory_limit = 128M      ; Maximum amount of memory a script may consume (128MB)

Line 307 is the one you want to change. Because I’m running locally, I set it to a high level, 128M of memory. If you’re on a hosted server, you probably won’t be able to get away with setting it this high.

Investigating your PHP configuration

WP Security plugin shows current PHP memory limit

WP Security plugin shows current PHP memory limit

There’s several ways to find your PHP memory limit. One way is to use the phpinfo(); function in a file, then load that file. This technique is extremely easy to find on Google, so I won’t waste our time here writing a superfluous explanation.

Another way, which should be much easier for you since you have installed the Website In A Weekend plugin security suite is to open the main page to the WP Security plugin. On the right side of the main page, several relevant parameters for your WordPress installation are listed out. The one we care about is in the green box. You can see it’s set to 64M. So far, that’s been enough for this blog.

If you have PHP memory trouble with your WordPress blog, I bet that number is 32M, or maybe even 16M. Too low. You need to increase your memory.

Increasing Bluehost’s PHP memory limits

Bluehost sets the PHP memory limits to a default value, 32M. When this isn’t enough, you have to increase it. I’m going to show you how to do that.

I’m using Bluehost as an example, but these instructions should work with any host that uses cPanel for administration. If your host doesn’t use cPanel, with a little thought, you should be able to figure out a procedure leading to the same result.

Your first step is firing up cPanel, and clicking on the PHP configuration icon, as shown in the screenshot below:

cPanel menu item for configuring PHP

cPanel menu item for configuring PHP

Now, you should be at a page that gives you a choice of several PHP configuration options. By default, the top radio button should be checked. You want the second radio button instead, “PHP5 (Single php.ini),” as denoted by item [1]. Then click item [2] to save the change in configuration. After the page reloads, click item [3] to write your php.ini in your public_html directory.

Change PHP configuration for your website

Change PHP configuration for your website

You’re not done yet!

Follow the instructions at the beginning of this article to change the value of the memory. You can do this by downloading the php.ini.default file, renaming it to php.ini, changing the memory value using a text editor on your computer, then uploading and overwriting the file written by the host. Or you can use the built-in cPanel file editor. Doesn’t really matter. Make a backup before you change anything!

A few notes to keep in mind:

  • When you change your parameters in your php.ini file, you may need to restart the webserver to force a reload. You may not… it depends on how Apache is configured. I restart Apache anyway on localhost.
  • On a hosted server, you may need to do a little research to figure what’s necessary for WordPress to use the increased value in it’s PHP scripts. According to years old threads in Bluehost’s forums, Bluehost’s servers are “smart” enough to figure out that php.ini files have been changed, and to reload without requiring an Apache restart. My experience is mixed… sometimes the changes work, but only after a while… cause and effect is difficult to establish.

Directing WordPress to use more memory

This tip is straight out of the WordPress Codex: use a WordPress directive to increase PHP memory. It looks like this in your wp-config.php file:

1
define('WP_MEMORY_LIMIT', '64M');

I’ve included this tip in this post because it’s simple and will save you time. Read the Codex discussion on wp-config.php here when you get a moment or two.

What if this isn’t enough?

In rare cases, this may not be enough. You may need to dig deeper into your WordPress installation and change individual files. Jeff Starr of Perishable Press has an excellent overview of how to accomplish this more advanced technique, when necessary. Here’s two articles you can take a look at:

  1. Improve Site Performance by Increasing PHP Memory for WordPress
  2. WordPress Error Fix(?): Increase PHP Memory for cache.php

>>>NOTE: Read these article carefully to ensure you know what you’re doing! Meddling with the .htaccess files can get you a 500 Server Error, so watch your logs at the same time.

“I’m still running out of memory!”

Ok, leave a comment explaining the problem as best you can. I may be able to help.