Posts Tagged: wordpress

0WordPress Local Gravatar cache

I like to have avatars shown for people who com­ment on my blog. Word­Press sup­ports the gravatar ser­vice nat­ively so enabling this is very easy. How­ever it comes with a cost — access­ing extern­al files from anoth­er domain adds lots of extra load time in the form of new DNS look­ups, new SSL con­nec­tions to make, etc. Wouldn’t it be nice to have gravatars stored loc­ally and served from your own serv­er. Well that’s what I’ve been doing for some time now, if you’d like to know how, read on…
Read Full Art­icle

0Localisation of Amazon Affiliates links

I occa­sion­ally ref­er­ence products on my vari­ous web­sites, and usu­ally link them to Amazon for any­one inter­ested in buy­ing them. A long time ago I used to link with an amazon affil­i­ates link but nev­er earned any­thing from it as my typ­ic­al read­er­ship is well dis­trib­uted around the world. Unfor­tu­nately Amazon don’t provide a way to redir­ect vis­it­ors to their loc­al amazon site whilst retain­ing to affil­i­ates pay­ments. There are vari­ous solu­tions out there but all the ones I found had issues with them, so I developed my own.… Read Full Art­icle

5Wordpress LogoAdsense ads above the last paragraph of a post

You may have noticed that we’ve tweaked how we dis­play our adsense ads.  We wanted some small text-only ads near the bot­tom of each art­icle, which would be added auto­mat­ic­ally.  This took a little bit of tinker­ing, but even­tu­ally we developed a solu­tion which works well and doesn’t seem to knock page pro­cessing times much.  Simply add the fol­low­ing code to your theme’s functions.php (don’t for­get to change your adsense IDs) … Read Full Art­icle

0Comment bubbleEasily set the parent of a WordPress comment

As is doc­u­mented in the site update log, for a while we had a prob­lem with our theme where it wasn’t pos­sible to reply to a com­ment so that the reply would appear cor­rectly in a threaded way.  We have no fixed this prob­lem, but have been left with a sig­ni­fic­ant num­ber of com­ments which really need edit­ing so it is easi­er to see what they are in reply to.  With a stand­ard word­press install this requires going into the data­base and edit­ing there, which is very tedi­ous.  Instead, we’ve used some simple func­tions to add an option to the com­ment-edit admin page, to set the com­ment par­ent there.  Even­tu­ally this will be developed into a prop­er plu­gin to enable this func­tion­al­ity.  For now the code is below, just add it to your theme’s functions.php

Read Full Art­icle

1Comment bubbleJetpack-style comments without Jetpack

One of the best things about word­press is the built-in social aspect provided by com­ments.  Get­ting your com­ment sec­tion right can be very import­ant to any web­site, includ­ing ours.  Over the years we’ve exper­i­mented with vari­ous com­ment plu­gins includ­ing Dis­qus and more recently Jet­pack.  How­ever, we’ve always ended up bring things back in house for man­age­ment, per­form­ance and pri­vacy reas­ons.  When I moved back from Jet­pack com­ments I really missed some of the slick fea­tures provided by Jet­pack, both the social-net­work logins and the gen­er­al slick styl­ing.  Any­way, to cut a long story short I finally had time today to take a good look at how word­press “does” com­ments and fig­ure out a way to build an in-house sys­tem which looks nice and slick like the com­ment inter­face provided by jet­pack.  Best of all its sur­pris­ingly simple and does things the “prop­er” way…
Read Full Art­icle

9Wordpress LogoRich Snippets code for the Twenty Eleven theme

I’ve pre­vi­ously detailed the code for enabling rich snip­pets in vari­ous word­press themes (Mys­tique 2, Mys­tique 3, Thes­is & Me Gusta) as well as some gen­er­ic instruc­tions. Below is a set of edits to enable rich snip­pets in the built-in word­press twenty elev­en theme.

Read Full Art­icle

0Wordpress LogoRich snippets code for Me Gusta theme

I’ve pre­vi­ously covered theme edits for rich snip­pets for vari­ous themes includ­ing Mys­tique 2, Mys­tique 3Thes­isTwenty Elev­en as well as some gen­er­ic instruc­tions.  Below are details of the code for how to val­id­ate rich snip­pets in the Me Gusta by Cos­mos theme.

Read Full Art­icle

2Wordpress LogoRich snippets code for Mystique 3.x

I’ve pre­vi­ously writ­ten about rich snip­pets code for Mys­tique 2.  There are also gen­er­ic instruc­tions and code for the themes twenty elev­enme gusta and thes­is.  Below is updated code for Mys­tique 3

Read Full Art­icle

0Wordpress LogoRich Snippets code for Mystique 2.x

In addi­tion to this site I have a per­son­al blog where, amongst oth­er things, I post recipes. I’ve recently dis­covered google’s new recipe search, and have been look­ing to imple­ment sup­port for micro­formats / microdata. Google provide a tool for check­ing your markup, called the “rich snip­pets test­ing tool”. When I tried val­id­at­ing one of my recipes, I encountered vari­ous errors, which have taken me a while to track down and resolve. … Read Full Art­icle

0DIY Media Home logoFew new articles, lots of new design work

For the last 2–3 months I’ve been too busy to write much new con­tent for the site.  This hasn’t been helped by a drop in things to write about  — most of my art­icles are about tech­no­logy fixes or excit­ing new HTPC related devel­op­ments.  There haven’t been too many new devel­op­ments, and I haven’t fixed much tech­no­logy because I’ve been too busy.  That doesn’t mean the site has been entirely ignored how­ever…

Read Full Art­icle