Dion Almaer's complete blog can be found at:
Items: 1 to 5 of 488
Next »
Monday, June 18, 2007
Is it me, or are browser user agents getting sillier and sillier and sillier:
Mozilla/5.0 (iPhone; U; CPU like Mac OS X; en) AppleWebKit/420+ (KHTML, like Gecko) Version/3.0 Mobile/1A542a Safari/419.3
I know that they result from testing, but sheesh. Extrapolate this to 2020 and what will we have?
Mozilla/5.0 (iPhone; U; CPU like Mac OS X; en) AppleWebKit/420+ (KHTML, like Gecko) Version/3.0 Mobile/1A542a Safari/419.3
I know that they result from testing, but sheesh. Extrapolate this to 2020 and what will we have?
Friday, June 15, 2007
Geography was always a let down for me in school. It was like history. It could be so interesting, but the teachers somehow managed to skirt the interesting topics, and instead have you learning inane boring content.
I wish we had tools such as GeoSense in the classroom.
It would be great to be able to "play a game" with other students. I would have really gotten into physical geography then. Also, it doesn't stop at just "where is some place in Africa". You can extend this to have information on all kinds of political, historical, and social issues that relate to geography.
I am sure todays teachers are wise to this and don't get up front in class and blabber on at the kids :/
I wish we had tools such as GeoSense in the classroom.
It would be great to be able to "play a game" with other students. I would have really gotten into physical geography then. Also, it doesn't stop at just "where is some place in Africa". You can extend this to have information on all kinds of political, historical, and social issues that relate to geography.
I am sure todays teachers are wise to this and don't get up front in class and blabber on at the kids :/
Wednesday, June 13, 2007
I am finding that more and more little applications that I have use Google Spreadsheets to store some data that I use in an Ajax app. After using the core API, you find yourself looking at fun code like foo.$t.
Most of the time I want a simple tabular view over a spreadsheet that has the first row as a header, and other rows as the data.
To do this I created GSpreadsheet which lets me do:
GSpreadsheet.load("pSYwzniwpzSFnt8Ix3ohQQA", { index: 'firstname' }, function(gs) {
// display all
document.getElementById("displayall").innerHTML = gs.displayAll();
// show one
var row = gs.select('Bob');
document.getElementById("onebyindex").innerHTML = row.email;
// show by row number
row = gs.select(1);
document.getElementById("onebyrownum").innerHTML = row.email;
// display one row
document.getElementById("displayrow").innerHTML = gs.displayRow('Bob');
});
You will see that you call GSpreadsheet.load(..., callback(takesAgsObject))
This is because of all of the asynchronous work going on. To get the JSON from the Spreadsheet back end you are always using the json-in-script output, and getting it by dynamically creating a script tag. The real dirty hack in this code is how to do that, and have the callback give you back the info to create the new object. To do this, I am creating a static method on the fly with eval() and calling into it passing in the right info. It's real ugly:
GSpreadsheet.load = function(key, options, callback) {
if (!options['worksheet']) options['worksheet'] = 'od6';
var worksheet = options['worksheet'];
var callbackName = "GSpreadsheet.loader_" + key + "_" + worksheet;
eval(callbackName + " = function(json) { var gs = new GSpreadsheet(key, json, options); callback(gs); }");
var script = document.createElement('script');
script.setAttribute('src', 'http://spreadsheets.google.com/feeds/list/' + key + '/' + worksheet + '/public/values' +
'?alt=json-in-script&callback=' + callbackName);
script.setAttribute('id', 'jsonScript');
script.setAttribute('type', 'text/javascript');
document.documentElement.firstChild.appendChild(script);
}
Most of the time I want a simple tabular view over a spreadsheet that has the first row as a header, and other rows as the data.
To do this I created GSpreadsheet which lets me do:
GSpreadsheet.load("pSYwzniwpzSFnt8Ix3ohQQA", { index: 'firstname' }, function(gs) {
// display all
document.getElementById("displayall").innerHTML = gs.displayAll();
// show one
var row = gs.select('Bob');
document.getElementById("onebyindex").innerHTML = row.email;
// show by row number
row = gs.select(1);
document.getElementById("onebyrownum").innerHTML = row.email;
// display one row
document.getElementById("displayrow").innerHTML = gs.displayRow('Bob');
});
You will see that you call GSpreadsheet.load(..., callback(takesAgsObject))
This is because of all of the asynchronous work going on. To get the JSON from the Spreadsheet back end you are always using the json-in-script output, and getting it by dynamically creating a script tag. The real dirty hack in this code is how to do that, and have the callback give you back the info to create the new object. To do this, I am creating a static method on the fly with eval() and calling into it passing in the right info. It's real ugly:
GSpreadsheet.load = function(key, options, callback) {
if (!options['worksheet']) options['worksheet'] = 'od6';
var worksheet = options['worksheet'];
var callbackName = "GSpreadsheet.loader_" + key + "_" + worksheet;
eval(callbackName + " = function(json) { var gs = new GSpreadsheet(key, json, options); callback(gs); }");
var script = document.createElement('script');
script.setAttribute('src', 'http://spreadsheets.google.com/feeds/list/' + key + '/' + worksheet + '/public/values' +
'?alt=json-in-script&callback=' + callbackName);
script.setAttribute('id', 'jsonScript');
script.setAttribute('type', 'text/javascript');
document.documentElement.firstChild.appendChild(script);
}
Wednesday, June 13, 2007
I have been waiting for this for awhile. You can now create the list of sites for a custom search engine on the fly.
This search below should search through my blogroll on the left (which I never update but that is another issue to do with me not generating the list from my opml feed like I should).
E.g. search for something like 'gears'. How it does this on the fly is quite impressive.
This search below should search through my blogroll on the left (which I never update but that is another issue to do with me not generating the list from my opml feed like I should).
E.g. search for something like 'gears'. How it does this on the fly is quite impressive.
Monday, June 11, 2007
This was an obvious step. Adobe has had to port WebKit to Windows for Apollo^H^H^H^H^H^H AIR. Apple had to port some of it for iTunes. The important piece here is WebKit (not Safari). The WebKit nightlies are insanely fast. I can't wait to hear how they run on Windows.
I am not sure exactly which target demographic will be running Safari on Windows though..... and of course, it means that we have yet another browser to support (although I am sure the windows version won't have any bugs different from the Mac version).
I am not sure exactly which target demographic will be running Safari on Windows though..... and of course, it means that we have yet another browser to support (although I am sure the windows version won't have any bugs different from the Mac version).
Items: 1 to 5 of 488
Next »

