Saturday, 16 April 2011

iphone web apps

I work on a mac at home and like it quite a lot, I am also a big fan of windows 7, so I have no axe to grind on the "fan boy" front. I have been working on a mobile development project recently and thought I would share my findings and thoughts. We decide to build a W3C Widget HTML, CSS and JavaScript packaged up as a web app. Because the iphone and Android don't yet support these we are wrapping them with the awesome Phonegap. At present, we are resisting the urge to use Phonegap for anything other than wrapping.

When Apple first said they wouldn't be supporting Flash on their mobile products, I thought it was a brave move and a sensible one. I justified it on the grounds that a big part of the problem with early Windows systems was that it allowed developers to do whatever they wanted. Many of the reported crashes with which Windows became synonymous were due to bad software rather than the operating system. I am mainly concentrating on "flash has not performed well" section of Apple's argument and less so on the "we're making the web an open field of delights with puppies for everyone" (1 of many sources on Apples position).

Developing on the iphone has given me a further glimpse into where this position has taken Apple. It's been quite interesting to work on a project where I have had multiple mobiles to develop on side by side.

Mobile libraries

Initially, we went for jQuery Mobile, which at the time was still in alpha. I think it will be an excellent product when finished if you want to do rapid mobile development using jQuery and it's theme system. I am not a bit fan of having the structure of my HTML and CSS taken away from me, especially by something in such early stage of development. So we decided to hand roll a mobile library, which was relatively easy, quite performant and a great learning experience.

position: fixed

At first we only had an Android to test on, while we waited for the iphone and developer licence - oh and the mac we'd need if we wanted to develop for the iphone... The app we built had a header, main and footer section. We affixed the header and footer with position: fixed and all was well. The first time we tested with iphone, we realised why jQuery mobile was using a JavaScript solution. Because many web sites built for desktop use large header and footers, supporting position: fixed could cause lots of sites to display poorly on a mobile phone. Apple's position seems to be to remove support for position: fixed as a preventative measure. PPK explains and has suggested a solution however, web developers are left hacking in fixes. We decided to hijack the touch events and build our own scrolling mechanism - on the iphone css transforms for the scrolling give a much better effect than the usual manipulating the CSS top.

Video

I was disappointed by my android when I found that it refused to play my html 5 video in either ogv or webm format when in webview mode (i.e. as a web page installed as an app). The same video would play perfectly well when browsed to normally. The iphone on the other hand was lovely, it played the video flawlessly, if you don't mind it taking control of the playing of the video fullscreen. However, the video element ignores all touch and click events. This is because it requires them for it's own controls. In theory, removing the control attribute from the video element should allow you to attach events, however, in our web app, this has not yet been the case - investigation continues.

I am torn here in that I like using my mac and it's ease of use, stability and performance. I dislike the reduction of freedom involved with the iphone and ipad - which is why I have an Android. But then, I bemoan the performance of my Android... What tears the balance for me, is developing for Apple, where I can't use standard code because Apple has deliberately stopped support without providing an alternative. This seems counter-intuitive from their point of view as it forces developers to introduce hacks outside of Apple's quality control.

Friday, 8 April 2011

Customer service tips

Ok, so, I am going to write this as a "how to improve your company's customer service" post to disguise the fact that it's merely a rant about Currys. Obviously I am going to avoid mentioning I purchased something from the same chain as PC World, because that makes everything that happened my own fault for choosing a company renowned for poor service.

Tip the first

Say a handsome young man walks into your store and orders a new fridge freezer. He then pays 10% extra just to have it delivered at a specific time. This customer is telling you something very important about his priorities: his time is worth more to him than that amount of money. This is very useful information if you want to keep him happy as a customer.

Tip the second

If you are going to use technology, use it wisely. If you have a "when will my stuff be delivered" section on your website, have it detect when the estimated delivery time has elapsed. If it has elapsed, offer the customer a contact route, remember, at this point they are likely frustrated.

As with the website, if you offer a phone service with a "if you are phoning about a delivery press..." service, if the delivery time has elapsed put the customer through to a representative, don't leave them with a constantly looping message telling them their item will be delivered at some point in the past.

Tip the third

Be helpful. I personally don't care how many times someone from a call centre tells me how sorry they are to hear I have an issue. I may be cynical but I am yet to be convinced of their genuine nature. This feeling is compounded when the person who is very sorry is also incapable or unwilling to be even remotely useful. I want to know when my item will be delivered and I also want a refund for the service I paid for and didn't get.

Tip the forth

Don't say stupid and annoying things which are not true. "I will fix this for you immediately":

  • That statement should not be followed by on hold music.
  • In my case, it would involve time travel.
  • "Fixing it" does not involve explaining why my delivery is late.
  • "Fixing it" does not involve not being able to give me a new ETA.
  • "Fixing it" does not involve not being able to give me a refund.

Tip the fifth

Make getting a refund easy. If someone pays money to save their time, making it difficult and time consuming to get a refund makes them feel cheated. Empower customer service people to give unhappy customers what they are looking for and entitled to.

Sunday, 27 March 2011

Top 5 games

This is a trip down memory lane and makes me want to install an emulator. You can have any game on the platform of your choice, with updated graphics, but the game play must remain the same.

  1. Elite

    Possibly my most fondly remembered game, I would have it as a console game now with updated graphics. I played this space based fighter / trading game for days and days, then weeks and months. It's open ended game-play allowed your imagination to turn it into a role-playing game inside your head. I, like so many others, think it should be resurrected as a modern game.

  2. Ultimate Doom

    I would have this as a console game too, with updated graphics. The arcade style action made this game ultimately re playable, it's one of the few games I can still clearly remember the route through quite a lot of the levels. It also had some amazing game-play moments, I still remember the ground shaking and seeing my first Cyberdemon - awesome. It also had fantastic level design and a co-op mode.

  3. World of Warcraft

    There's not much to be said about wow - it's like the heroin of addictive games, nothing else will suck down the hours quite like it. With a decent group of friends, there are few gaming experiences to match it. It is probably unrivalled in delivering memorable gaming moments, from your first epic, to seeing the Fel Reavers for the first time. I only stopped playing when world pvp become almost impossible to find.

  4. Unreal Tournament 2004

    My favourite online shooter of all time, I even spent hours practising against the bots. Bombing run was one of the best game types I have played - shame no-one else agreed and it was removed from future versions.

  5. Super Smash T.V.

    I wouldn't change a thing about this game, not the controls, the graphics, the console and certainly not the cheesy one liners "I'd buy that for a dollar". Way too many happy memories of both single player and 2 player mode.

Honourable Mentions

There are lots of amazing games I missed out - notably the plot driven games, which I feel lack the longevity for this type of scenario - Half Life (I didn't get into the multiplayer), System Shock 2, Assassin's Creed II, Dead Space 2. I also didn't have room for Quake 2 or Diablo - really looking forward to Diablo 3.

Top 5 T.V. Shows

This is a tough one as there are so many good series that were cut short with only 1 or 2 seasons (Terminator: The Sarah Connor Chronicles). Conversely, there are many average shows which aired relentlessly. Quality or quantity... hmmmmm.

  1. Archer

    Only in it's second series, but definitely the best thing on T.V. atm by some considerable distance. Adult viewing, not for the faint hearted, but it really does make me laugh. There are some things that only an animated series can get away with.

  2. Sons of Anarchy

    Another amazing series from FX. This details the ups and downs of a motor bike club. The premise didn't grip me at all at first, but I was badgered into watching it and was gripped from episode one. Fantastic story and great characters.

  3. Married with Children

    An oldie, but a goodie. What can I say, Al Bundie makes me laugh and he is personally responsible for my love of New York Cheesecake.

  4. American Dad

    I have too many fond memories of Stan and Rodger to miss this one out. When a series has added new accents and phrases to your way of speaking, you know it's had an effect - "Dimmer switches!". I have championed American Dad over Family Guy and seen a few people come round to my way of thinking.

  5. House

    As with all the series mentioned here, I can watch re-runs of house all day. I take the criticism that the episodes are formulaic - no-one knows whats wrong with the patient; things get worse till House decides to do something totally unorthodox; everyone disagrees, but House is right and saves the day. I don't watch the series to see what happens to the patients though, I watch it for the characters and the sub plots.

Honorable Mentions

Breaking Bad is an outstanding series, but it is very much story driven, so it's replay ability is low for this list - highly recommended though. Firefly was terminated during the first season, but was awesome. Fringe is a very easy watch too.

Top 5 babes in heaven

Because it's heaven you get five babes frozen in time at their prime. Choose well, as you have to spend eternity with them!

  1. Park Min Young

    A korean dancer who is fated to be the next Mrs Ant, as well as being an amazing dancer, her t.v. interviews seem to show her as impossibly sweet as well. If I was to watch one video for the rest of my days, it would be the one linked in the above.

  2. Michelle Pfeiffer

    She is just the awesome, no meal in heaven would be complete without her draped over a piano singing to me ala The Fabulous Baker Boys. She is probably my only enduring crush...

  3. Audrey Hepburn

    A true icon and IMHO one of the most beautiful women of all time. I haven't read much about her life, but I would be absolutely gutted to read that she wasn't a nice person. In the theatre of my mind, she is as sweet as she is lovely.

  4. Charisma Carpenter

    As well as being stunning, her character in Buffy the Vampire Slayer rocked the show. It seems in real life she's into rock climbing and fitness, it doesn't get much better than that!

  5. Elisha Cuthbert

    Unlike many of the other top 5's I was hard pressed to fill this one. I remember Elisha making my toes curl when I watched 24, but I've not seen much of her since.

In the honorable mentions list I would add Elle Macpherson and probably Kelly Brook, but really, I'd be happy with my top 4. I would worry that I may neglect number 5 and that would be rude...

Friday, 25 March 2011

Top 5's

I quite like making lists of things I like and trying to get the perfect 5. Rather than just being my favourite 5, the 5 things have to complement each other so that they create the perfect grouping. Here's my current thoughts on things, written down so I can look back and see how my thoughts have changed.

Top 5 authors to take take to heaven

If I was allowed to take the complete works of 5 authors to heaven and read only these books for the rest of eternity. So the authors have to be varied in pace, style and subject matter. They also have to have a fairly large collection of works to keep me going. This last point in some ways caused me the most grief - I've had to leave behind some of my favourite books because the author was lazy :)

  1. Ernest Hemingway

    I really love the way Hemingway writes, so I would be happy re-reading his works and even studying them to some extent. As he wrote some of my favourite books (especially The Old Man and the Sea) he was pretty much a shoe in for first place.

  2. Philip K. Dick

    Another shoe in, my favourite sci fi author and a prolific writer. His books are interesting, thought provoking and worthy of re-reads. His writing style sometimes requires effort on the readers part, though always well rewarded.

  3. David Gemmel

    My first "easy read" author, Gemmel was a childhood favourite and I still find many of his characters as engaging today as I did back then. His work is intelligent heroic fantasy and since his sad passing I have struggled to find a replacement author for the genre.

  4. Cormac McCarthy

    I just couldn't go to heaven without a copy of The Road, I rate it as my favourite novel mainly due to the prose. He paints a picture of such draining darkness that you see the characters in black and white. His other works are also excellent, but The Road is transcendant.

  5. Robert Anton Wilson

    One of the truly great minds of our time and a personal hero. He wrote both fiction and non-fiction on a truly inspiring variety of topics. Whilst some of his work was so heavily based in the ethos and culture of the 70's it seems a bit dated stylistically, the ideas are as relevant today as ever.

Honorable mentions

There are so many honourable mentions it's just as hard trimming these down. First off, I am sad I have no Eastern authors in my list, both Bulgakov and Turgenev were definitely in the running. Vonnegut was replaced by McCarthy. I will miss Heinlein's Starship Troopers and Job II, but along with William Gibson and Neal Stephenson he was pushed out by Philip K. Dick. Herman Hesse and A. E. Housman would have added to the collection with their style and subject matter. I also really like Jeff Lindsay, author of the Dexter novels of the popular TV series. Still, if making the list was easy, it would be no fun.

What would yours be?

Sunday, 20 March 2011

Popular Science

I am quite a big fan of popular science and have been watching prof Brian Cox's Horizon series with interest. I think it's an awesome show and I like the way information is presented to the viewer. However, I have been wondering for a while about scientific "leaps of faith". I don't see anyway around them and as part of my own view on the universe, I am quite happy to make them, simply because I understand that is what I am doing. My concern is that recently I have seen people accepting things as fact because "science says it is so".

"Can you get the project finished by Friday, yes or no?". Despite being the question being couched to provoke a boolean response, the question may well have more than 2 correct answers. The most correct is likely to be "Well, it depends". Despite being the most correct it is likely to be one of the least satisfactory possible answers to the asker. People don't like uncertainty and this often clouds the answers we give or alters the way we talk.

Leaps of faith

If I am making a point the validity of my argument will rest on some key ideas. If my argument rests on the value of x in the following: x - 2 = 7 and I state that x is 5, almost everyone will be in a position to know if I am correct or not immediately. However, if I state that for the inequality 3x - 7 > 5x + 11, x < -9, well, I'm guessing that the number of people who would go to the effort of solving the problem decreases significantly. If I then argue that E = mc2, well I think you see where I am going.

Of course, the validity of my claim can also be tested in practical application. For example, if I am talking about the pressure of a gas increasing with temperature and quote pV = NkT (the ideal gas law) you can rely on the fact that this is principle through which steam engines work. Thus gaining a degree of confidence in my point without resorting to first principles.

There are circumstances where the evidence isn't completely in yet and statements are made based on a consensus of opinion using the data that is currently available. One statement like this would be "the universe is 13.7 billion years old and will go on for ever...". The current evidence does seem to point in that direction, however, it's not the only possibility. It is possible that at some point in the future a new source of dark matter will be discovered, giving the universe sufficient mass to be closed. It doesn't seem likely, but it's far from impossible.

Reasons for post

I worry about the blind belief in "science" without the necessary tools for reasonable scepticism. Being wrong about the ultimate fate of the universe is one thing, but being wrong about the right type of medicine for you is entirely another. Whilst I applaud the current wave of scepticism over religion and homoeopathy, it unfortunately seems to go hand in hand with a blind acceptance of "scientific" western medicine. Pharmaceuticals are not produced by people working in the pursuit of pure knowledge, they are created by large corporations built to produce profit.

The current scientific thoughts on a subject are not dogma. Science is not a religion with absolute truths being handed down from on high. The scientific method is merely the best way we know of to solve problems and find answers. It is based on trying to find fault with the current theories of the day. It requires you to be sceptical of everything, not just those ideas which are not currently in fashion.