Christian Heilmann

Author Archive

Webmonkey brings you zooming images – again

Saturday, February 25th, 2006

Skimming through my referrers and their blogs I just found the Live Thumbnails: Watch ‘em Grow article that explains how to make a non-boring image gallery.

I thought at first it’ll be something like my Image previews with DOM JavaScript but it turns out to be a script that automatically resizes images with a timeout when you click them. Apart from the HTML resizing still looking ugly as hell and slow on a busy machine, something in the back of my head rang: I had seen webmonkey publish something like that before, and I used all my google-fu skills to find it: It was an article published in 1997, called something like making stuff zoom .

Good to see that we have come a long way with JavaScript. Now we don’t use code forking and exclusively catering to MSIE, but instead we use invalid attributes. While PPK’s JavaScript triggers article rightfully explains that you should use an own DTD if you come up with own attributes, the Webmonkey one sadly forgets about this and instead relies on you also reading and understanding the JavaScript triggers one.

How about we just make sure we publish interesting photos?

By the way: I would have loved to comment at webmonkey, but I cannot be bothered to send an email.

Google Pages – Google enters the WYSIWYG page editing market

Saturday, February 25th, 2006

I just stumbled upon Google Pages, which seems to be a cleaner geocities/myspace/homestead. You can create web pages in a live editing WYSIWYG environment and choose a style and a layout. The resulting code is not as grim as I expected it:

Googlepages creates CSS layouts with embedded styles, which is not really perfect, but a step in the right direction. You can edit, publish and unpublish pages quite easily. It seems even adult content is all right to publish, but I will not test that now! I created the demo page in FireFox 1.5 on PC, as Googlepages so far does neither support Safari, Camino nor Firefox on my Mac.

I’d like to see a chance to submit templates…

Using position:fixed and transparency in a creative way

Thursday, February 23rd, 2006

Some time ago, design for CSSZenGarden using a knife that slashes through the document was all the rage.

Now I stumbled upon a referrer in my stats that got me sniggering: blether.com has a much more subtle gimmick like that, and I am sure that if you open this site on public terminals you’ll encounter a lot of people scratching the screen.

Mapsurface – another very slick site statistics thingamajing

Thursday, February 23rd, 2006

Andy Budd reported yesterday about mapsurface , a new site statistics tool that does all the others do, but with the difference that it shows the data live on the site without the admin or statistics-interested visitors having to log into a backend editor.

I really like what I can see on Andy’s site and signed up for a test drive. However, I really hope that there is a chance to password-protect the stats, as for now it is a good blogger or web admin “pat our own back” tool, but will be hard to sell on the market.

Nearly every client I ever had wanted statistics tools, hardly any did anything useful with the collected information, but what all agreed on was that they didn’t want their competitors to see their stats.

Therefore it’d be a clever move (unless that is already anticipated in the full version) to allow for different levels of access – with a preliminary log-in on the site.

You can test mapsurface on the developers blog: Glenn Jones on his very own mapsurface or sign up for a test run on http://www.mapsurface.com.

Freddy vs JSON – Lots of noise about OO JavaScript

Tuesday, February 21st, 2006

It is amazing how something dormant for a long time in the developer community emerges simultaneously at different spots.

My own Show love to the object literal was basically intended to explain the OL as a coding style and syntax allowing your scripts to be self-contained.

Dustin Diaz had a similar post cooking for quite a while and released his JSON for the masses a day later. His post is very enthusiastic about the whole subject, but does confuse some matters.

As always, and through the wonders of remote scripting (yes, I coined that term for comments being added at other people’s blogs linking to your own) a lot of discussions arose. Once again the hardliners of OO development tried to get JS to follow the same rules as higher programming languages, whereas JavaScript novices got very excited about some inconsistencies that might actually prevail as a myth for a longer time now. It is amazing how JavaScript sits in the middle of the whole development spectrum and everybody has an own – very fixed – idea about what good JS is. I got one, too, and there is a draft here about that subject (Hint: It does what it is supposed to do, and is easy to maintain by the intended audience).

Read all about how Dustin and me got informed about what is wrong or what is good about what we said:

Now here is my view on the matter:

The object literal

I like the OL as a syntax, and explained why in the post: It could be a signal that a script is more modern and was developed with unobtrusivity (hah! I guess nobody used that one yet) in mind. It is high time to find a mean for JavaScript novices to spot what is good to use these days and what is debris from the DHTML days. We could also call all our scripts “beta”, that’d also make them smack of Web 2.0!

Jason, err JSON

I like JSON as a data format, but it is not the same as the OL. JSON is a subset of the OL, and basically is a scripting syntax version of XML: It is there to hold data to send it back and forth in a readable and easily convertible way. JSON allows and encourages things like:

var data={
'my wedding':'fat and Greek',
'Plan':'9 from outer space',
'Red Hot Chili Peppers':'Flea, Anthony, and many random others'
}

This would be quite confusing in a script, although you can read out data['my wedding'] all the same. I’d consider it harmful as part of a script, as it does not quite promote valid variable names.

How about this: Calling JSON and the OL the same thing is as misleading as calling XML and semantic markup the same thing. One is data, the other is good practice (yes, you are allowed a different opinion).

And what about OO JavaScript then?

Now, if you want to go down and dirty with the real OO of JavaScript, then Tim Scarfe comes to your rescue with these two wonderful articles.