Sunday, September 14th 2008

Snaz – mobile shopping
posted @ 5:21 am in [ Flash -iPhone -Javascript -Mobile -Technology -Web Design ]

I was tidying up an old hard-drive I had today, and came across this article from New Media Age where we talked to them about Snaz, our mobile shopping solution from the days of early .com

 Interestingly the idea is still good, however now that the browsers on phones are so good that they can run Javascript and interpret style sheets, the need for rendering on the fly is a little defunct.

Still it’s funny how the world goes 360 and we are now at Skywire producing iPhone and Blackberry friendly versions of our clients’ websites, which have their own detection code, as the iPhone can’t run Flash at the moment and the Blackberry’s rendering engine is terrible!

Snaz : New Media Age

Friday, April 18th 2008

Configuring your iPhone for T-Mobile
posted @ 10:20 am in [ Fixing Things -iPhone -Mobile -Technology ]

My iPhone is on T-Mobile as the ex-owner wanted to keep the O2 number that came with it, and I have a corporate account with T-Mobile.

All works nicely, but obviously you want to configure your T-Mobile account to mimick the default iPhone account that it originally came with, so here’s what you need.

1. T-Mobile Web & Walk

You need to add the very reasonable £7.99 package to your account and wait a few hours for it to be activated, then you get up to a Gig of data a month (I believe) to play with.

2. Configure the EDGE settings on your iPhone

Settings -> General -> Network – EDGE

Username = user
Password = pass

et voila – off browsing we go when we’re away from the wireless network!

Thursday, January 24th 2008

Receiving and Decoding MMS messages using Apache
posted @ 8:02 am in [ Apache -Kannel -MBuni -MMS -Mobile -PHP ]

A quick follow onto the post below of how to use Apache to serve MMS messages, one other interesting thing you can do with Apache is use it to receive MMS messages from a phone.

Basically, this just requires a little bit of lateral thinking, and some clever PHP and then you can see exactly which headers a phone uses to create the MMS messages it sends itself – and in our case use this to work out which fields we should be including in our MMS messages.

Step 1: Configure your phone to send MMS messages to your own Apache server, not the default operator MMSC.

This really depends on what phone you have, but if you dig around in the MMS settings within the phone, you will eventually find a menu option labelled MMS Server Name or similar. On a Motorola Razor V3 for example this is in Messages -> (option menu) -> Message Setup -> Change -> Server Info ->(option menu) -> Edit -> Server Name

Change this to be your own Apache server, for example in our case, or an IP address if you have one may be even better if your operator doesn’t support DNS look-ups.

Step 2: Create your MMS on the phone

Step 3: Add you MMS receiving code to your Apache server

There’s lots of good packages out there to do this, including mBlogging software such as b2evolution and Peffisaur however for our decoding we used a nice piece of PHP coding from the following article on creating an MMSC.

Step 4: Send your message from your phone to your server

Step 5: Decode your MMS message

Now you have the MMS message as a binary file, but you really want something handy to decode it for you, so this is where a handy PHP class called MMS Decoder comes in handy. By default this reads from an HTTP stream, but with the following few modifications you can make it read from files instead.

$filename = "test.mms";

if (is_readable($filename)) {
	$handle = fopen($filename, "r");
	$mmsdata = fread($handle, filesize($filename));

// parse MMS
$mms = new MMSDecoder($mmsdata);

// The MMS is parsed, so let's get the mms data from the class by the print_r() function,echo(print_r($mms, true));


Voila! All the headers from your phone built MMS ready for you to emulate in your own messages to ensure the phone receives them.

Thursday, January 24th 2008

Serving MMS messages with Apache
posted @ 7:29 am in [ Apache -Kannel -MBuni -MMS -Mobile -PHP ]

Now you would have thought after the number of years I’ve been playing around with MMS messages, using libraries like the Nokia MMS Java library to build them and servers like Kannel (SMS) and MBuni (MMS) to serve them, that we wouldn’t have any problems trying to serve MMS content ourselves using SMS binary push and .MMS encoded files.

Well, basically we did – and it all comes down to one thing – phones needing be specifically told that .MMS messages have a certain MIME type.

Some phones, the Motorola V3 Razor for example, automatically assume that all MMS messages are going to be an acceptable type, no matter what MIME type you serve them as. Therefore using a standard Apache server, a binary created MMS file (try the Nokia MMS Java library for Java, and MMSLib for PHP to build the messages) and a binary SMS push (either made yourself or using HTTP API’s such as Clickatell’s) these phones recieve the messages just fine.

However, a lot of other phones (notably Blackberry’s and Sony Ericsson’s) require specific instructions to treat the .mms file as type application/vnd.wap.mms-message

Therefore for these phones, add into the directory where the .mms files are stored the following .htaccess file and Apache will start serving the content in exactly the right way.

AddType application/vnd.wap.mms-message mms

Job done – and I bet if you’re reading because this is what you’re trying to do, we hopefully just saved you hours of going mad!