Author

me.jpeg

I am a web developer specialising in web driven applications using PHP, MySQL, Symfony and Zend and I am currently working for the The Drum in Glasgow, Scotland.

Most days I can be found frantically coding away with EuroDance in my ears and consuming what I hope to be a never ending supply of coffee... happy days!

Sencha Touch for the PHP Developer

The beginning of the year saw me working on the latest version of the Herald Scotland app (both android and iOS versions were released at the beginning of May) using Sencha Touch and PhoneGap. App development is not one of my primary skills and the learning curve from my comfort zone of PHP to Sencha Touch has been a steep one and one which I'm still far from conquering, however I thought it might be useful to share some of what i have learned and hopefully steers others away from some of the issues I encountered.

traditional-page.jpg

If you only take away one thing from this article then it should be to forget everything you know about web development and start again... Sencha Touch is an entirely different beast to what you are used to.

Read more

Using setSharedMaxAge() with HttpCache in Symfony2 always returns s-maxage=0

When implementing HttpCache within one of our Symfony2 projects I came across a curious problem in that regardless what I set the shared max age to it would always show as s-maxage=0 in the network inspector and the cache result was always a miss.  This puzzled me and so to try and isolate the issue I broke it down to the most basic example I could, but even then I still experienced the same s-maxage=0 problem.

My simple example was

Read more

"-":4: bad minute when installing crontab from a file

I recently had to migrate a rather messy crontab from one server to another and to try and simplify things I wanted to split the crontab into managable chunks.  

Unfortunately the crontab does not have any import / include functionality and I didn't want to use different user accounts to have different crontabs (this would likely cause permission issues, a management headache, and I would be replacing one messy solution with another) so after a quick Google I found that the solution was to create the separate files and concatentate them into the crontab. i.e.

Read more

#htmlmovies - A bit of nerd humour

A colleague of mine pointed me in the direction of a humorous twitter hashtag of the IT variety which, with being a web developer I found quite amusing, especially on a friday afternoon.  The hashtag was for #htmlmovies.

If you've not already guessed, the basic idea is to convey a film is a clever way using html tags such as

Read more

Import Product Attributes into Magento

I have recently taken on a new web project which is to move an e-commerce website from a custom 3rd party solution over to Magento and before I even got started I hit a road block (you have got to love Magento for that!).  I found that I had to import around 200 product attributes (colours, sizes, etc) from the old online shop to the magento installation and obviously I did not want to enter all these by hand, but where to begin?!

Luckily I came across a post on the Magento forums which details a method for bulk importing product attributes into Magento and although it did not allow me to automate the whole process, it was sufficient for my purposes.

Read more

VPN Issues with O2 Wireless Box II - Firmware Download

I wrote an article in April 2010 about VPN Issues with O2 Wireless Box II and it has come to my attention that O2 are now putting firmware version 8.2.7.7 on their routers which is supposed to resolve these VPN issues. Apparently this is not always the case and O2 are no longer downgrading the firmware because it is "fixed" in the 8.2.7.7 version.  Some people are finding it difficult to get any support, and the O2 CD which you can download no longer has the older 7.4.20.4 firmware.

Fear not though... I did a little digging around and managed to located the 7.4.20.4 firmware (RT-585v7_74K4EJ.exe) and I have upload it for you.

Read more

Is Auto-Tweeting Bad?

Over the few weeks I have taken to reading (yes, honestly I have, and it appears there is a decent amount of worthwhile reading material out there on the web) a few blog entries from SEOmoz, partly because I started to follow SEOmoz on twitter and have been enticed by twitter teasers.

One of the points of thought on a recent blog entry about the unexpected effects of a tweet on search engine rankings suggested that auto-tweeting using tools like auto-tweet plugins for Wordpress or online services such as Twitterfeed were not as effective as promoting the content.

Read more

Wordpress, Nginx, PHP Fast CGI and an unprivileged user account

Over the last month or so I have been busy migrating my sites from my old shared hosting to a new server in the Rackspace Cloud and it has not been without it troubles. The first site I transferred was my Wordpress blog and after following various resources on setting up Nginx and spawning PHP FastCGI processes I managed to get everything up and running happily... or so I thought.

As it turns out I had followed the guide for spawing PHP FastCGI processes to the letter, and that is where the problem lay.  After a few weeks Wordpress reported there were various plugins that needed upgrading but I could not do the automatic upgrade and I had trouble uploading new files due to the wrong permission being applied.  After some investigation this lead me to realise that I needed to spawn my PHP FastCGI processes as the unprivileged user the files belonged to, and not nginx as in the original documentation.

Read more


Server Backup using Dropbox (A 5 Minute Setup)

I am one of those people who, despite knowing the risks, fail to make appropriate backups of my work and important data and rely on hope that nothing will go wrong.  Unfortunately I have been caught out on a couple of occasions and I have been after a nice way to backup my data (documents, websites under development, family photos etc) from my home Fedora Core server without me having to really do anything.

dropbox_logo.jpg

I have seen several online backup software solutions, however most have to be configured and managed via GUI applications installed on your computer however as I have been wanting to back up a Fedora Core server which is command line only, this options was not available to me.  A few people suggested Dropbox to me for sharing files between home and work computers and when looking into Dropbox I found that it can also be set up with a service on my Fedora Core server and configured to backup the data on my server.

Read more

Advertisement

Digital Ocean

Chris's Reading List

www.thoughtworks.com

BFF @ SoundCloud

Our friends at SoundCloud embarked on a journey a few years ago that changed their system and moved it from a monolithic Rails application towards an ecosystem of microservices. Read more

The Drum

The Drum

Google'€™s AMP is bringing some much needed speed to mobile but the transition won'€™t be easy for publishers

A week after launching, the Google-led Accelerated Mobile Pages (AMP) initiative has raised more questions than answers for publishers... Read more

SitePoint

SitePoint

Quick Tip: How to Permanently Change SQL Mode in MySQL

MySQL 5.7 introduced some awkward changes for older codebases and tends to break apps. Here's how to temporarily (or permanently) lower the strictness level Read more

SitePoint

SitePoint

How to Build Your Own Dependency Injection Container

Andrew Carter builds a Dependency Injection container from scratch, showing you how that rocket science is really just fireworks strapped to lego figures! Read more

AuthorityLabs

AuthorityLabs

13 Reasons Your Organic Traffic is in Decline | It's Not a Penalty

The landscape of search engine optimization has changed drastically in the last 3-4 years. Even as it changes, a lot stays the same. It has been very challenging to see a multitude of friends and colleagues approach me with problems that often seem beyond repair with clients that they have worked with for years. Read more

TechCrunch

TechCrunch

WordPress Sites Now Support Google’s AMP To Make Mobile Pages Load Much Faster

Google has some big plans when it comes to making the web faster on your mobile phone. The company just added AMP-enabled pages in its mobile search results... Read more