You may have noticed that we’ve tweaked how we display our adsense ads. We wanted some small text-only ads near the bottom of each article, which would be added automatically. This took a little bit of tinkering, but eventually we developed a solution which works well and doesn’t seem to knock page processing times much. Simply add the following code to your theme’s functions.php (don’t forget to change your adsense IDs) … Read Full Article
Posts Categorised: Computing
5
0
Easily set the parent of a WordPress comment
As is documented in the site update log, for a while we had a problem with our theme where it wasn’t possible to reply to a comment so that the reply would appear correctly in a threaded way. We have no fixed this problem, but have been left with a significant number of comments which really need editing so it is easier to see what they are in reply to. With a standard wordpress install this requires going into the database and editing there, which is very tedious. Instead, we’ve used some simple functions to add an option to the comment-edit admin page, to set the comment parent there. Eventually this will be developed into a proper plugin to enable this functionality. For now the code is below, just add it to your theme’s functions.php
0
Batch convert old MS Office documents
I’ve been trying to sort out an enormous (100+GB) or teaching resources that I’ve built-up over the years. After the obvious steps (deleting empty, temp and duplicated files) and sorting the big files (e.g. videos, application installers) I was left with a large number of office documents. I am slowly working through these, but many of them are 2003 or even older format documents — some as old as Word 6! Every time I open one of these files I am prompted with various security warnings. Whist these can be turned off (see below) it is more secure to leave them on, and I wanted to convert all the files to office 2007 (docx, xlsx etc) formats. Batch conversion was definitely the way to go.
0
Install a spellchecker for your browser
Let me start with an admission: I’m one of those pedants on Facebook who likes to correct your spelling, punctuation and grammar. Some of you will think this is perfectly reasonable, whilst others will probably want an explanation. If you are one of the latter read on.
The simple fact is that as a social species our existence depends on communication, the clearer the better. When their only contact with you is virtual other people will make judgements about you based on what is available to them — including your SPG. I correct spellings on Facebook for 2 reasons: 1. because I’m a teacher so it’s a habit; 2. because with modern web-browsers there is quite simply no excuse for incorrect spelling. So, to help everyone, here is a quick guide to enabling an automatic ‘Microsoft word like” spell-checker in your web-browser…
1
Jetpack-style comments without Jetpack
One of the best things about wordpress is the built-in social aspect provided by comments. Getting your comment section right can be very important to any website, including ours. Over the years we’ve experimented with various comment plugins including Disqus and more recently Jetpack. However, we’ve always ended up bring things back in house for management, performance and privacy reasons. When I moved back from Jetpack comments I really missed some of the slick features provided by Jetpack, both the social-network logins and the general slick styling. Anyway, to cut a long story short I finally had time today to take a good look at how wordpress “does” comments and figure out a way to build an in-house system which looks nice and slick like the comment interface provided by jetpack. Best of all its surprisingly simple and does things the “proper” way…
… Read Full Article
0
HTML5 spec finished and published!
At long last, the W3C has published the final HTML5 specification. DIY Media Home is already written coded in HTML5, but the finalisation of the specification means that HTML5 compliance is no longer a moving target for either us, or the browser makers. Hopefully all the main players will provide fully HTML5 compliant browsers soon. In the meantime we’ll be working to ensure our site is fully compliant with the final spec.
0
How to reduce spam with SPF, DKIM & DMARC
Since I set up contact forms on various websites I’ve had a slowly increasing volume of spam. Not direct spam sent to me, but bounces from non-existent addresses that were being spamme, apparently from my address. Unfortunately the spam wasn’t originating from my address, but my address was somehow picked up (probably from before I secured the contact forms on the site) and was being used as the “reply to” address. After some investigation I heard about SPF which is an e‑mail anti-forgery system.
7
Conditional formatting for grades v targets
So, in my other life I’m actually a science teacher, and as it usually gets round that I’m “good with computers” I usually get asked to have a look at a few things. Twice in the last few months I’ve been asked if I’d set up conditional formatting in excel to colour code student test results compared to their target grades. Whilst not exactly related to the core content of this site, it is still DIY technical help so I decided to publish a full set of instructions here. Enjoy…
… Read Full Article
0
Budget desktop PC comparison 2011 to 2012
Each year, around xmas, I publish a recommended budget PC article. This year I’m doing it slightly early, but decided to directly compare the spec and price this year with last year to see how things have developed.
9
Rich Snippets code for the Twenty Eleven theme
I’ve previously detailed the code for enabling rich snippets in various wordpress themes ([intlink id=“2948” type=“post”]Mystique 2[/intlink], [intlink id=“2949” type=“post”]Mystique 3[/intlink], [intlink id=“2468” type=“post”]Thesis[/intlink] & [intlink id=“3017” type=“post”]Me Gusta[/intlink]) as well as some [intlink id=“1520” type=“post”]generic instructions[/intlink]. Below is a set of edits to enable rich snippets in the built-in wordpress twenty eleven theme.
“Hi James I realise it has been a long while, but I just checked this on windows 11 (build 23H2)…”