Author Archive

Utilising the TweetMeme API

TweetMeme logoWe’ve been integrating some social media into one of the sites we work on ModernSelling and specifically working with the TweetMeme API which allows users to view the number of Tweets an article / page has received and retweet said article. From the horse’s mouth:

The TweetMeme retweet button is for website and blog publishers who want to encourage their audience to tweet their content on Twitter. The button shows a live count of the number of times your webpage or blog post has been tweeted.

There are a few points worth mentioning about this integration because it is not always as straightforward as you might think and perhaps some of this information will be of use.

Firstly, TweetMeme is quite strict so for anti-spam purposes uses a combination of the Tweet which we send to the API and a custom meta tag containing a match of the tweet:

<meta name=”tweetmeme-title” content=”The Message of the tweet ” />

Additionally, the content / message of the tweet has to be a direct subset of the HTML title tag. For instance, for the example above, ‘The Message of the tweet’ needs to be included in <title>. It doesn’t have to be the only thing in the title tag but it does have to be present.

So if like us you are generating these things on the fly (the site in question is driven by a content management system we built) you may have to make adjustments to your system to accommodate the TweetMeme functionality and also discuss compromises with your client; for instance, in our case, the title tag now includes the original title (which was specifically written for SEO purposes) with the article headline (which we want to be the body of the tweet) appended to the end. There is no way around this – the tweet message cannot contain something that is not contained in the HTML title tag so you need to live with it or not use the TweetMeme API.

Secondly, TweetMeme uses a cache which means that if someone already tweeted your page/s before you implemented the TweetMeme functionality the tweet will already be cached against the url. In these instances, if you wish a retweet to use the a new message as opposed to the old, incorrect message (your old title tag if it was incorrect) you need to clear the TweetMeme cache on a page-by-page basis or, rather than doing a manual update for a large number of URL’s you can automate the process and use the TweetMeme ping api (http://api.tweetmeme.com/ping?url=).  Just append the URL that you want to update at the end of it and loop through the list of pages on your site.

Finally, part of the site we implemented this feature on is subscription only so bare in mind that any password protected url is not going to allow the TweetMeme API to make a call back to the page to verify it – TweetMeme will not work in these circumstances.

Happy TweetMeme’ing!

Action Message Format (AMF)

Traitors Flash game title image

We have recently built a Flash Game – Traitors – for the Top Gear website:

The game, sponsored by Nissan, requires the user to speed through 3 levels controlling their speed by repeatedly pressing X-Y buttons as fast as they can and using their booster. For the purpose of data submission and receiving data while interacting with the webserver we decided to use AMFPHP which is open-source implementation of the Action Message Format (AMF) and allows binary serialisation of Action Script (AS2 and AS3) native types and objects to be sent directly to server side services. Phew…

The crux of this is the ease of implementing data transfers to and from the webserver (less code on both client application and on the webserver) and the efficiency of the resultant transfer (the data being transferred is binary format which is also compressed further in AMF3 so the amount of data being transferred is smaller). This is brilliant for rapid development (which we do a lot of) and performance of the finished article.

For instance, on the webserver you don’t have to loop through a database recordset, compose some XML and return that XML to Flash which would then load and parse the XML: you can essentially return the recordset directly from php to Flash and the query is automatically converted to the corresponding ActionScript type. There are several processes being skipped and the data being transferred is far smaller (being compressed binary as opposed to XML).

DECODE: Digital Design Sensations

Decodehttp://www.vam.ac.uk/microsites/decode/

We decided to have a company outing to Decode @ V&A last Friday and trotted off to West London (yes, we do venture out of East London) to see what we could see.

The blurb states:

“Decode: Digital Design Sensations showcases the latest developments in digital and interactive design, from small, screen-based, graphics to large-scale interactive installations.”

And

“Decode is a collaboration between the V&A and onedotzero, a contemporary arts organisation operating internationally with a remit to promote innovation across all forms of moving image and interactive arts.”

From a visitors’ perspective the exhibition was interesting enough; quite a lot of interactive art installations which capture, record and insert the audiences contribution (for example a video ‘wall’). And others works which use interesting data sources (such as stock market data) to as the source of algorithmic animations. In some ways though there was nothing we hadn’t seen before in terms of technology and this is where we became a little critical of the exhibition: for all the slickness of the works, it felt to a few of us that something was missing – what was the meaning of things? For instance, a lot of the work in the exhibition played on the fact that people seemingly love to have their 5 minutes of fame and hence fall over themselves to be filmed, pictured, captured in some way and displayed for others to look at. But what is the intended meaning of the art? Is there any actual cultural or personal message hidden in them? It didn’t look to me like there was and as such the exhibition fell short of what art can offer people (excite by all means but also get the audience thinking). I didn’t see any obvious cultural references, or personal messages existential or otherwise. As an example, there was an algorithmic animation which was generated from ‘stock market data’ according to the blurb. All well and good but no further explanation was given, it looked nice but think of the possibilities involved in this subject of telling a story, making a comment about capitalism / money and the state of the economy and what effect this has on society (obviously poignant now). It’s a shame it didn’t explore these meaningful avenues or if it did that the blurb about the work didn’t even mention it (they often sided on a practical explanation of how it was achieved / built).

As such, some of the exhibition felt a little more like the interactive section within the science museum as opposed to any great art exhibition – great fun and visually stimulating but lacking an underlying meaning (of course the science museum obviously has an educational remit it fulfils). I wonder what people in 100 years will think when they look back at this period of digital art? I suppose they may come to the conclusion that the early 21st century signified the beginning of a new art movement but at the same time, as art goes, was a little naïve; getting carried away with new technology at the expense of what art is actually all about.

I might be looking at this too critically and I guess there is nothing wrong with showing off techniques and new found skills, after all the great artists of the renaissance and beyond have often done just that but I would like to see an industry I am involved in attempting to merge the technology with the fundamental reasons why art is so important to everyone – to get us thinking about things (anything!).

Cake of the Month: Moon Cake

Picture of a Moon Cake

Halloween special – Mooncake! And what a cake; brought back as a present from Hong Kong this cake holds a dirty little secret. Inside, AKA Scotch egg style is a duck egg yolk. You might think this is normal, ‘cakes are made with egg’ I hear you say. But this one actually has a solid egg in the middle and so deserves another picture (below). Suffice to say that it didn’t go down particularly well in the office. In fact, I was the only one who tried a second bite and certainly the only person to partake in the egg. According to Wikipedia Mooncakes are “rich, heavy, and dense compared with most Western cakes and pastries.” You can say that again.

Still, in the spirit of Halloween, these cakes are for the Zhongqiu Festival for lunar worship and moon watching. So fill your boots!

Inside of Mooncake

Sash windows: a luxury we can afford

UV Office

After 8 years hunkered down in the Truman Brewery, Brick Lane, in what can only be described as ‘cosy’ surroundings we have moved to a bigger, brighter, fresher and more creative space! We haven’t moved far (physically) but things are far from the same in our nice new airy, windowed office. We even have a sofa. It’s been a long time coming but it was worth the wait…patience as they say is a virtue.

PHP Security

An image of a framework

There are many PHP users out there who probably don’t come from a computer science background; after all, it is probably the most accessible server-side technology out there so why shouldn’t more people have access to building dynamic, data-driven web sites/applications? However combine this with the very nature of the PHP rapid application development model and various PHP frameworks/content management systems and there are possible (and well documented) security issues. My guess is that some people are just not aware of these issues due to inexperience, others overlook them in their rush to get the job done quickly and some might even think because they are using a pre-built framework/CMS that the issues have already been taken care of. Classic asp had similar issues which were dealt with in the rollout of asp.net (particularly v2.0 onwards).

I’m not going to list all the issues (well known ones include cross-site scripting vulnerabilities, SQL injection and session hijacking) but suffice to say there is much online discussion (some productive and some not so) and additionally a rather decent book: ‘Essential PHP Security’ by Chris Shiflett available from Amazon and other good bookstores.

CMS Vs Framework

About a year ago we decided to add to our development offerings and move into PHP based web development. Up until then we had predominantly used windows based server side technology (classic asp and then asp.net, c# etc) mainly because a good number of our customers were using Windows hosting (IIS) and required us to follow suit. We’ve been happy to do this and still have many clients running web sites and applications utilising the .net framework. However, it came to be for several key reasons that adding PHP to our key skills made sense for our business and for our clients. Here’s just a few:

  • Recruitment: the majority of web design / new media courses include server side modules and universities tend to use PHP; therefore it’s easier to recruit and employ a graduate who has already received some formal training and doesn’t require re-skilling
  • Open standard: with plenty of support and knowledge available plus with cost benefits which we can pass onto our customers
  • Hosting: cost effective web and database hosting
  • Rapid development: with the multitude of support and understanding out there we can quickly build upon others peoples ideas and knowledge

I’d be interested in other’s opinions / additions to this list…. I am sure there are many.

Once we’d made the decision, we mulled over several options. One was to source a pre-made content management system and the latter a PHP framework. Having looked at various CMS we installed and trialed DRUPAL (http://drupal.org/). Our initial thoughts were that we could release CMS driven sites pretty quickly and easily and concentrate on the UI design and front end design aspects. However, it became clear that for a business so used to providing bespoke builds with initial business analysis and design that we were not comfortable with having too much of the development control taken out of our hands – and that is how it seemed with DRUPAL. Additionally, DRUPAL is all things to all men in the CMS world but our belief is that our customers would prefer a little less complexity: we are used to building CMS from the ground up to enable our customers to perform the tasks they require easily and with minimal training. Our worry was that we would potentially be delivering something that performed the task but was not quite what our customers were envisaging. I’d also say that there was a potential danger in us losing part of what makes us good at what we do – sitting down with a customer and listening to what it is they want and then suggesting a solution with impartiality (ie: using the best technology for the job).

So our search moved on and we researched several PHP frameworks in the belief that we could find a happy medium between ‘from the ground up’ development and using an off the shelf CMS, providing us the flexibility and freedom to offer fully bespoke, customised solutions but allowing us to build rapidly and effectively using pre-built modules that can be plugged into your own business entities. Based on several recommendations and a good few months trialing we have settled on using CodeIgniter (http://codeigniter.com/) and have begun to build our own CMS around the framework. Thus far I am happy to report it is just the job and we have had a great deal of success. Soon we will post some more specific information about the projects involved.

New employee

New employee

On the 15th January 2009 we finally found a new member of staff after 9 months of rigorous interviews. We have been waiting 1 month for him to work his notice period but our new developer – Vandon – started work for us today. He’s doing remarkably good for someone with slightly less experience than we had originally been looking for.

Friday feeling (x52)

Everyone must have had that project? The one that keeps on trukin right through the project deadline, right through the next week and for whatever reason (and there are numerous legitimate ones) right through to a point when you don’t remember a time without it? I *think* we have just completed one of those projects and somehow, although there is relief that we may well get paid for our hard work, it’s left a hole where once it existed as wee bit of code!

Anyhow, the project is pretty decent, it’s built as an actionscript project using Flex to compile and an example of it is posted online here.

One World, One Browser?

We are currently working on some CSS for a client who requested the site be created to ‘Level Triple-A Conformance to Web Content Accessibility Guidelines 1.0’. For those who wish to know this is a guideline by the W3C and conformance to Priority 1, Priority 2, and Priority 3:

‘Conformance to these Guidelines will help make the Web more accessible to users with disabilities and will benefit all users.’

The site contains quite a bit of complexity and rich content and we have also built an interactive Flash component in AS3 for part of the site which requires alternative content.

We like to think we are pretty good at CSS and have built the site with all the pre-requisites. The only trouble is that when it came to releasing a test version of the site to the client, he was using Internet Explorer 6 (at the time of posting this accounts for 25% of all web browsers so not to be ignored).

We have spent the day painstakingly going through the site page by page to make it look and function just as it does in Internet Explorer 7, Firefox (of course) and Safari.

This got us thinking about starting a campaign: “One World, One Browser”

(and of course let it be Firefox)

You may well say that this is dictatorial, anti-competitive, unimaginative even. But after tonight, who cares.

JOIN US. WE ARE ONE.

PS: More info on Accessibility on W3C here

Search