Clock Blog

Our responsive toolkit

Posted on Wednesday, 8 May 2013 @ 00:00 GMT in tech-blogs by Ben Gourley

Here at Clock, the vast majority of our web projects are now responsive. Whether we implement a fully fluid design or a set of fixed breakpoints, we now approach projects with an extended armoury – making sure we deliver a top experience across devices. Here's a run down of some of the tools and libraries that help us along the way…

Preventing 'http: Raise hangup error on destroyed socket write' from crashing your node.js server

Posted on Wednesday, 20 February 2013 @ 19:37 GMT in tech-blogs by Paul Serby

This is our approach to preventing your node.js web server from crashing because of the hang up now thrown in nodejs 0.8.20

An Introduction to Backbone.js

Posted on Wednesday, 30 January 2013 @ 00:00 GMT in tech-blogs by Ben Gourley

Last week I gave a presentation on Backbone.js to the rest of the developers here at Clock. The amount of exposure we've had to client side heavy-lifting varies, so the idea was to get everyone on the same page. The other guys found it pretty handy, so I thought I'd write it up here where there's a…

The Black Art of Background Processing

Posted on Tuesday, 22 January 2013 @ 16:55 GMT in tech-blogs by Oliver Johnstone

A discussion on the different techniques we can use to process large tasks in a web environment.

Passing the Zend 5.3 PHP Certification

Posted on Monday, 10 December 2012 @ 08:09 GMT in tech-blogs by Tom Smith

My experience of revising and passing the Zend 5.3 PHP Certification

How to create a private npm.js repository

Posted on Tuesday, 20 November 2012 @ 12:56 GMT in tech-blogs by Tom Gallacher

npmjs.org never goes down, or so we thought.

Top Picks of the LXJS Talks

Posted on Thursday, 4 October 2012 @ 11:52 GMT in tech-blogs by Ben Gourley

Seven of us Clockers made the trip to Lisbon for LXJS last week. The overall quality of the talks was excellent. There was a great balance of abstract and technical content, and luckily for you (if you didn't make it to the conference, or just want to relive the experience) the organisers have done a great job getting the video live-streamed and already uploaded to YouTube...

Optimise your pngs from the terminal in OSX

Posted on Tuesday, 2 October 2012 @ 09:56 GMT in tech-blogs by Paul Serby

A simple guide to optimising all of your png using a single command.

How to keep data synchronised using Node JS

Posted on Wednesday, 22 August 2012 @ 00:00 GMT in tech-blogs by Adam Duncan

A module we developed to help us keep data in sync

Git Bisect: Simple Examples and Automation

Posted on Sunday, 19 August 2012 @ 13:59 GMT in tech-blogs by Luke Wilde

A brief introduction into Git bisect and an example of it's automation

Use jQuery Events on Plain JavaScript Objects

Posted on Wednesday, 25 July 2012 @ 00:00 GMT in tech-blogs by Ben Gourley

Did you know that you can use jQuery events on non-DOM-related objects? Just wrap up the object in the jQuery function, and you can use on, off and trigger.

Automated Cross Browser Testing: The Holy Grail

Posted on Thursday, 12 July 2012 @ 00:00 GMT in tech-blogs by Ben Gourley

Update: One of the authors of Buster.js helpfully responded to this article on Twitter, pointing out that a new version had been released since I'd tried it. This new version addresses IE support, which was one of my major qualms as mentioned later in the post. When writing module.js, I wanted to…

iOS & JavaScript event response time optimisation

Posted on Tuesday, 19 June 2012 @ 21:36 GMT in tech-blogs by Luke Wilde

When developing HTML5 applications with JavaScript, iOS click and touch response times are infamously slow. Here's some advice from down in the trenches here at Clock on how to improve the responsiveness of your applications.

A Simple Website in Node.js with Express, Jade and Stylus

Posted on Monday, 11 June 2012 @ 00:00 GMT in tech-blogs by Ben Gourley

This post will use the popular Express framework to show you how you can build simple websites in Node.

Clock Embracing Next-Generation Internet

Posted on Wednesday, 6 June 2012 @ 08:09 GMT in tech-blogs by Michael Cronnelly

We are official participants of World IPv6 Launch, a coordinated adoption of the next-generation Internet protocol.

Doctrine ORM Associations

Posted on Monday, 28 May 2012 @ 08:07 GMT in tech-blogs by Tom Smith

Doctrine ORM Associations define the relationships between entities and are responsible for setting up the foreign keys and enforcing referential integrity.

Scaling Node.js and MongoDB on Joyent Cloud

Posted on Wednesday, 29 February 2012 @ 20:12 GMT in tech-blogs by Michael Cronnelly

Here at Clock, we recently deployed a large Node.js and MongoDB application for a client to Joyent's cloud platform, designed for horizontal scalability. This document gives a brief overview of the configuration, and observations in the setup. We are not explaining how to design a scalable…

PHP Conference 2012

Posted on Friday, 24 February 2012 @ 06:42 GMT in tech-blogs by Robert Arnold

Today is Clock's 5th annual trip to the PHP Conference and generally speaking, it gets better each year. The keynote this year is by Rasmus Lerdorf entitled "A look at PHP in 2012", and as the PHP conf site tells us, Rasmus is: Best known for having gotten the PHP project off the ground in 1995. He…

versionator - Static content versioning in node.js using express

Posted on Friday, 17 February 2012 @ 15:17 GMT in tech-blogs by Paul Serby

versionator was built to solve the problem of static assets getting stuck in browser and proxy caches when new versions of the assets are deployed. Without versionator this is what can happen: You set your static content to be cached and expire in 30 days time. express.static(__dirname +…

Upstart and Node.js

Posted on Monday, 6 February 2012 @ 11:28 GMT in tech-blogs by Iain Grant

One issue that we have had with Node.js projects is how to allow our developers to assume the role of devops for the various different sites a machine may be running - i.e. to restart node sites without incurring a large overhead in server configuration. To date we have been running our node sites…

Zsh: [Ctrl + left arrow] outputting '5D'?

Posted on Wednesday, 11 January 2012 @ 11:51 GMT in tech-blogs by Luke Wilde

If you've recently started using Zsh as your shell of choice and have noticed that some key bindings are not working or are now outputting unusual characters, you need to update your .zshrc. I noticed the issue on a virtual machine running Ubuntu Server, however, other systems vary and output…

Compiling ActionScript 3.0 with Sublime Text 2

Posted on Monday, 5 December 2011 @ 16:41 GMT in tech-blogs by Luke Wilde

At Clock we typically spend our time developing JavaScript and PHP, however, occasionally Flash presents itself as the most suitable platform for certain components.  To avoid the need of installing a separate authoring environment (and even the license fees associated with some of the official…

How to interview for a Front-End Developer (and what any decent applicant should know)

Posted on Thursday, 13 October 2011 @ 09:52 GMT in tech-blogs by Andrew Devlin

A friend of mine (who's just started his own digital agency) got in touch the other day to ask the question: "We're interviewing for a front-end developer this week and [not being a front-ender] I was wondering if you could give me some tips on what topics we should cover?" Not a problem at all, I…

Code readability: The 5 minute explanation test.

Posted on Tuesday, 4 October 2011 @ 10:31 GMT in tech-blogs by Robert Arnold

As the great man, Albert Einstein, once reportedly said: "If you can't explain it simply, you don't understand it well enough." I was reading an article by Alberto Gutierrez on makinggoodsoftware.com and within the article he touches upon a technique that we *sometimes-but-not-often-enough*…

Deleting a git commit

Posted on Friday, 9 September 2011 @ 12:32 GMT in tech-blogs by Tom Smith

When working with Git you will find that sometimes commits need to be removed as they have introduced a bug or need to be reworked. If it is the last commit this is very straight forward. Simply run: git reset HEAD This will pop off the latest commit but leave all of your changes to the files…

Basics: Always send urls

Posted on Monday, 5 September 2011 @ 21:17 GMT in tech-blogs by Paul Serby

As a rule of thumb we should ensure that we always send URLs to clients / friend / co-workers when instructing them to do something on a website. Relying on others to know what is meant by 'staging version', 'live version', 'account section', 'sign-up' page is thwart with danger and room for…

Why you should be using VERP (Variable Envelope Return Path)

Posted on Thursday, 1 September 2011 @ 09:39 GMT in tech-blogs by Robert Arnold

You may not have heard of VERP, but it is very important that you find out whether your email campaign software/service uses it. Variable Envelope Return Path or "VERP" is a technique to enable automatic detection and removal of undeliverable e-mail addresses. I have previously used email campaign…

My Stylus Mixin for CSS3 Linear Gradients in Node

Posted on Thursday, 14 July 2011 @ 11:15 GMT in tech-blogs by Andrew Devlin

I've been getting my hands dirty with more Node development recently, and one of the best parts of it as a front-end developer is the utilisation of Stylus. Stylus, combined with Jade speeds up my output so much. I love the cleanliness of the markup (well, what markup there is) - it's clean,…

Which branch should I be working on?

Posted on Monday, 13 June 2011 @ 23:29 GMT in tech-blogs by Paul Serby

Here at Clock we have recently switched from svn to git; it is awesome. If you don't already know that you should try it for a month. Git is both powerful and flexible and this allows you to adopt sophisticated branching models which can improve the quality of your development process…

My pre-concerns of nodeJS

Posted on Thursday, 9 June 2011 @ 15:07 GMT in tech-blogs by Robert Arnold

Recently, our tech team has got well into nodeJS - even recently launching our first project utilising it. I am (sadly) at the beginning, with hardly any prior knowledge about this strange-mystical-yet-exciting technology. My concerns with it are: Stability & Security Support Having to…

The Very Best of Clock's Bookmarks

Posted on Friday, 13 May 2011 @ 22:15 GMT in tech-blogs by Ben Hutton

At Clock, we like to keep up to date with what's happening in the industry. One of our key three aims is to be "bleeding edge". Since I stared my placement at Clock back in July 2010, we've been sharing useful and interesting links via email and Delicious. This post contains what I believe are the…

What World of Warcraft taught me about Project Management

Posted on Friday, 6 May 2011 @ 12:45 GMT in tech-blogs by Kosala Ubayasekara

The Lesson Until about 4 years ago I was a major elitist when it came to work and skills. I just refused to work with people below a certain standard of coding or execution excellence and often found myself struggling with projects that, despite have elite teams of people throughout, never seemed…

HTML5 contentEditable CMS?

Posted on Friday, 6 May 2011 @ 10:23 GMT in tech-blogs by Robert Arnold

This is a blog post of an idea, rather than the critique of such a system or nuisances thereof. I have done some quick Google searches to see if there is anyone out there using the new html5 'contentEditable' feature to perform content management system tools for a Web site - and whilst there are…

Bash Completion Problems with option lists generated by PHP

Posted on Wednesday, 4 May 2011 @ 23:25 GMT in tech-blogs by Paul Serby

When creating bash completion scripts that get fed from PHP, I realised I was getting the following problem: I would type the command then press tab to get the completion $maiden<tab><tab> But nothing would happen except the cursor jump forward. I would then not be able to backspace…

Exporting Postgres Tables as CSV

Posted on Wednesday, 20 April 2011 @ 14:53 GMT in tech-blogs by Paul Serby

If you need to get a quick CVS of a large query output to a client in a CSV and are using PgAdmin3 or some other GUI tool running on your local machine you might want to considering running this command on the database server directly.  echo "COPY (SELECT * FROM \"User\") TO STDOUT CSV;" | psql -U…

Deploying node.js apps

Posted on Monday, 11 April 2011 @ 17:50 GMT in tech-blogs by Ben Gourley

Here at Clock, long gone are the days of FTP uploads to put a site live. We use deployment tools to automate the process, which have the advantage of being faster, while reducing the chance of human error. I'm delving into node.js development, for which I've set up my own deployment and…

PHPExcel Cheatsheet

Posted on Friday, 8 April 2011 @ 19:04 GMT in tech-blogs by Tom Smith

PHPExcel is a collection of classes that allows you to generate excel documents in PHP. It is incredibly powerful and you can perform almost all (if not all) task that you would normally use in excel. It is really easy to install, either download the files or they now have a pear channel. For more…

SCRUM Lite - Project Management for Small Teams

Posted on Friday, 8 April 2011 @ 12:55 GMT in tech-blogs by Kosala Ubayasekara

Now...anyone that has done any work utilising SCRUM will happily tell you that implementing the full SCRUM method into a small development team is quite difficult...even unnecessary. Ask any SCRUM instructer and they will tell you if you DON'T implement the full SCRUM method ... then you aren't…

A School Report: Optimisation...

Posted on Monday, 4 April 2011 @ 17:38 GMT in tech-blogs by Robert Arnold

A couple of useful tools that we use for checking page speed (and optimisation of) are 'YSlow' and 'Google Labs: Google Page Speed'. To run through some of the nuances and discussions we have internally, I thought it might be a nice exercise to blog about the ones I discovered for our very own…

Forrst - The essential power-up to Software Development

Posted on Monday, 21 March 2011 @ 10:39 GMT in tech-blogs by Ben Hutton

Over the last year I've noticed people posting links on twitter to their latest design, a new layout they want feedback on, or even something graphically compelling. These links however, were Forrst links, and to anyone outside of Forrst, inaccessible (By default, but users can change). Not being a…

Avoiding Superfluous HTML5

Posted on Monday, 7 March 2011 @ 12:11 GMT in tech-blogs by Andrew Devlin

HTML5 (or rather, the continuing specification of HTML) is very, very good really great stuff. New elements, better semantic meaning to mark-up, more accessible interactivity - it's all leading to some very exciting times ahead, and with those times I hope that we'll start to see more and more…

Virtualbox 4.0.4 Shared Folder Update

Posted on Sunday, 20 February 2011 @ 11:29 GMT in tech-blogs by Paul Serby

Continuing from previous blog post, I have benchmarked the newest release of Virtualbox 4.0.4 with Shared Folder access. Same test as before, benchmarking static content servered up by apache from a Shared Folder using the follow command: $ ab -c 10 -n 500…

VirtualBox 4.0 Shared Folders Still Slow

Posted on Friday, 7 January 2011 @ 14:41 GMT in tech-blogs by Paul Serby

I've recently installed the newest version of VirtualBox. I had every finger and toe crossed in the hope that my long standing bug with Shared Folders would be fixed. We run an Ubuntu 10.04.1 VM and use a Apache/PHP stack and serve up sites using files from a folder on the host environment. This…

Phing Filterset Custom Task

Posted on Monday, 13 September 2010 @ 17:06 GMT in tech-blogs by Dom Udall

I couldn't find anywhere online to quickly show me how to use filtersets in a custom phing target, so I worked it out myself and thought I'd bash it out here. Not much to it I know, but always nice for a reference! Filtersets allow recursion through files with specific includes and excludes, and…

Eclipse PDT Templates assisting CS

Posted on Wednesday, 14 July 2010 @ 16:48 GMT in tech-blogs by Robert Arnold

Coding Standards are important for a number of reasons: Standards allow everyone to follow the same practices, which lowers the learning curve when moving between projects. Coding standards make the reading of source code easier, thus lowering the time needed by a developer to understand it. …

The Future of Captcha?

Posted on Tuesday, 13 July 2010 @ 14:00 GMT in tech-blogs by Tom Smith

I saw an interesting post on forrst.com this morning which was a screenshot of a planned method for making Captcha easier for users and still stop robots / spammers from filling out your forms. Captcha at the moment requires users to decipher a series of distorted characters and enter them in a…

Mooving the Atom & H.264 Video Codec

Posted on Tuesday, 29 June 2010 @ 20:13 GMT in tech-blogs by Elliot Coad

Today I was held up by our Flash video player not progressively downloading a seemingly regular F4V video uploaded by a client. The symptoms of this meant that the person watching the video would get a blank screen up until 100% of the video had downloaded, often minutes later. I used G-Spot to…

URL shortners, undoing DNS

Posted on Monday, 21 June 2010 @ 13:49 GMT in tech-blogs by Robert Arnold

I am by no means an expert in DNS or the like, but as my colleague (Mike) and I were discussing, the premise of DNS was to turn IP Addresses of servers, which are humanly unreadable (just numbers) into URLs that are readable and understandable by humans (i.e www.amazon.com). Now, as if…

Branching Policy for SVN

Posted on Sunday, 20 June 2010 @ 00:22 GMT in tech-blogs by Paul Serby

Recently I've been looking into the prospect of switching from our current SCM system of SVN to GIT. Linus gives a pretty convincing argument in this video (Thanks to Michael Cronnelly our Head of Technical Services for hooking me up with this) but for us the business case is not strong enough at…

The Joys of Patch Files

Posted on Tuesday, 27 April 2010 @ 22:22 GMT in tech-blogs by Dom Udall

I haven't been working with SVN that long, but the more I use it, the more I think I couldn't develop properly without it. Today I ran into an issue that I knew would crop up at some point, but for some reason never had. Let me set the scene: I'm currently working on a large project which is in the…

Missing my friends - Access Visibility in PHP

Posted on Friday, 26 March 2010 @ 23:46 GMT in tech-blogs by Paul Serby

Is it only me who wants to see the friend access visibility added to PHP so classes within the same package can call each others methods? Now we have Namespaces in 5.3 I see no reason why this form of access visibility has been left out. Friend or Internal as it is called in C# is added to…