In the back of the book there is a mash-up of flickr and google maps. I decided to do a mashup of twitter and google maps. Im well aware of twittervision, but the problem with it is that its the public-time line, not your friends, sooo… i decided to mash-up your friends updates with google maps in a twittervision style.
Heres how I got on (abridged):
Iteration 1 : Get one thing working. Got api key from google maps, displayed a simple map
Then i realised… cross site scripting problems. Basically this means you cant go from one website to another and get data, through the browser. IE and firefox will thing you are trying to be naughty and stop you. There are several work arounds
Iteration 3: Keep the pace by keeping it working. One work around is to send the request not from website a to website b, but from website a, to website a… which then sends it to website b on the server side and returns the response to the client. I wrote an 8 line c# http server so if you submitted a request to http://localhost/proxy.html?url=http://twitter.com/statuses/friends_timeline.json, it will proxy the request. That worked fine. So i linked the twitter data with the google maps data and everything worked
Iteration 4: Refactor, refactor . I wanted to get rid of the server side proxy as I wanted it totally client side. Enter this little gem Twitter Undocumented Hacks (!!!!) . The bit i used was the Dynamic script tag.
Anyways, check it out http://www.simplewebphone.com/YouTwit.html, as soon as the page loads you’ll be asked for your twitter credentials, type them in and see what you think.
Over the next few weeks ill see how I can jazz it up!