Programming

Auto Load Your PHP Classes

Posted on

In PHP you can create classes to organise your code and represent objects that you want to pass around. This has long been a feature of other languages and was a fundamentally important step forward for PHP. There was one thing, though, that I didn’t like about PHP classes. If I wanted to instantiate a […]

Programming

JavaScript and Noisy HTML

Posted on

I was answering a question on a popular coding forum and it once again highlighted the age old problem of terribly bad JavaScript. This was the HTML code in question: <a id=”image1″ href=”#”><img src=”image.png”></a> And there was a bit of JavaScript adding an onclick event to the anchor tag. An innocent looking example. An anchor […]

Programming

JavaScript Namespacing

Posted on

This is just a quick article to demonstrate a quick bit of JavaScript namespacing. Why would you do this? Well, this allows you to put functions and variables inside of an identifier. It acts like a “box of stuff” and prevents variable and function name conflicts. It also supplies a neat way to organise and […]

Programming

TransactionScope and WCF Services

Posted on

The problem I encountered was that, while I had started a TransactionScope in my calling method (and could even see a current transaction in my services) – an error in a second WCF service call was NOT rolling back the changes made in a previous WCF service call. The behaviour was as if each service […]

Browsers

Microsoft Expression Super Compare

Posted on

Revised, July 2014. I have no idea what became of this product – I think it got rolled into a premium version of the Expression suite, but can’t find any references to it. Original article below… Microsoft have just released a really cool new tool for comparing websites in different versions of the Internet Explorer […]

Browsers

HTML5 Browser Test

Posted on

Revised, July 2014 – Please see my update on dropping the HTML5 shim. Having managed to get the HTML5 website working in all the popular browsers, I ran a test on a larger number of browsers and operating systems with the following result: If you are running the latest version of any major browser – […]

Programming

Fenton JavaScript Ethos

Posted on

When JavaScript was first created (hurriedly) by Brendan Eich, the idea was to allow people to add a bit of interaction to a web page. Since its inception, JavaScript has grown into a massive part of the Internet and, like all technologies, it has sometimes been used in a bad way. Here’s the thing about […]

Programming

Google Uses Image Sprites

Posted on

I happened be using the worlds most popular browser (sic) and I noticed a strange appearance on Google… If you look really closely, below the logo there are three strange lines. I very quick investigation revealed the result, which is the use of sprites on web pages. A sprite is, essentially, all of the images […]