Archive for June, 2007

Today on eBay: George W. Bush’s Watch

Hah, Bush went to Albania, probably the only place outside a Born-Again-Christian-Nuthouse where they still love him, and got his watch stolen.

Cue Nelson’s “Ha! Ha!”.

So when’s the bombing planned for? I’m sure Wolfowitz and Rumsfeld are already planning a retaliation and they’ll get, uhm, let me pull a country name out of the hat of countries they don’t like… Belgium for this as well!

And Tony Snow’s already saying he took it off himself, despite no evidence to support it. Ah, spin, spin, spin. The “Emperor has no clothes!”, everybody yells, “The Emperor is fully clothed!” he says, and everybody just shuts up again. Is Tony Snow a fucking Jedi or something?

But props to the Albanian pickpocket, he’ll sure have bragging rights, “I stole the watch of President of the USA!”

Google Maps Latitude and Longitude

Updated

Inspired by the post from Lifehacker, which is a re-post from tech-recipes, here’s how to get Google Maps coordinates in degrees, minutes and seconds:

javascript:coord = [gApplication.getMap().getCenter().lat(),gApplication.getMap().getCenter().lng()];
output = '';
for (x in [0,1]) {
	neg = (coord[x] < 0);
	if (neg) coord[x] *= -1;
	deg = Math.floor(coord[x]);
	minr = (coord[x] - deg) * 60;
	min = Math.floor(minr);
	sec = Math.floor((minr - min) * 60 * 100000)/100000;
	output += (x==0?'Lat':', Long') + ': ' + deg + "° " + (min < 10?'0':'') + min + "' " + (sec < 10?'0':'') + sec + '" ' + (x==0?(neg?'S':'N'):(neg?'W':'E'));
};
void(prompt('', output));

Also do-able in one line ;-) :

javascript:coord=[gApplication.getMap().getCenter().lat(),gApplication.getMap().getCenter().lng()];output='';for(x in [0,1]){neg=(coord[x]<0);if (neg) coord[x]*=-1;deg=Math.floor(coord[x]);minr=(coord[x]-deg)*60;min=Math.floor(minr);sec=Math.floor((minr - min)*60*100000)/100000;output+=(x==0?'Lat':', Long')+': '+deg+"° "+(min<10?'0':'')+min+"' "+(sec<10?'0':'')+sec+'" '+(x==0?(neg?'S':'N'):(neg?'W':'E'));};void(prompt('',output));

How to use? Just open up Google Maps, center the view to the place you want the coordinates of and paste the one-liner into the address bar. Or make a new bookmark, paste the line into “Location”, and “open” the bookmark while you’re in Google Maps.

Yay!

Of course, the question is, use +/- notation or north/south and east/west?

Le Update 1

Roger wanted the output to be pastable into Google Maps. Not hard actually…

Google Maps Compatible Output
javascript:coord=[gApplication.getMap().getCenter().lat(),gApplication.getMap().getCenter().lng()];output='';for(x in [0,1]){neg=(coord[x]<0);if (neg) coord[x]*=-1;deg=Math.floor(coord[x]);minr=(coord[x]-deg)*60;min=Math.floor(minr);sec=Math.floor((minr - min)*60*100000)/100000;output+=deg+"° "+(min<10?'0':'')+min+"' "+(sec<10?'0':'')+sec+'" '+(x==0?(neg?'S ':'N '):(neg?'W':'E'));};void(prompt('',output));

and ThomasV tried to comment but WordPress trying to be smart broke his quotes. I guess MapSource is a program?

MapSource Compatible Output
javascript:coord = [gApplication.getMap().getCenter().lat(),gApplication.getMap().getCenter().lng()]; output = ''; for (x in [0,1]) { neg = (coord[x] < 0); if (neg) coord[x] *= -1; output += (x==0?(neg?'S':'N'):(neg?'W':'E')) + coord[x] + ' '; }; void(prompt('', output));
Update 2009-02-08: Target Box

I updated the code, it now inserts a small semi-transparent box in the middle of the map, click on it and it will tell you the coordinates of the cent(re|er) of the map. Yay!

javascript:var tgt = document.createElement('div'); tgt.setAttribute('style', 'border: 1px solid blue; background-color: white; position: absolute; top: 49%; left: 49%; height: 2%; width: 2%; opacity: 0.5;'); tgt.onclick = function() { coord=[gApplication.getMap().getCenter().lat(),gApplication.getMap().getCenter().lng()];output='';for(x in [0,1]){neg=(coord[x]<0);if (neg) coord[x]*=-1;deg=Math.floor(coord[x]);minr=(coord[x]-deg)*60;min=Math.floor(minr);sec=Math.floor((minr - min)*60*100000)/100000;output+=(x==0?'Lat':', Long')+': '+deg+"° "+(min<10?'0':'')+min+"' "+(sec<10?'0':'')+sec+'" '+(x==0?(neg?'S':'N') : (neg?'W':'E'));};prompt('Coordinates',output); }; void(document.getElementById('map').appendChild(tgt));

Paris Hilton

Aah, Paris Hilton. Sorry about the choice of topic, but I gotta write about mainstream news once in a while. :) Much to the chagrin of Al Gore, I am sure.

I’m sure they have “Free Paris!” t-shirts, doesn’t matter tounge-in-cheekly or not. Anybody made “Put Paris back in Jail!” t-shirts yet?



Follow

Get every new post delivered to your Inbox.