[thelist] AJAX Tip

Lee kowalkowski lee.kowalkowski at googlemail.com
Thu Apr 6 08:03:06 CDT 2006


On 06/04/06, Christian Heilmann <codepo8 at gmail.com> wrote:
>
> > > > How do you NOT use the DOM when you want to do unobtrusive
> Scripting?
> > > > Even if it is DOM-1?


OK, how do you not use the DOM to do DHTML these days?

> > <a href="picture.jpg" onclick="return showPicture(this, 'picture.jpg
> ');"><img
> > > src="thumbnail.jpg" /></a>
> >
> > That is the part that is not unobtrusive.  There should not be JS in
> > the markup.

Exactly. Unobtrusive JavaScript should be unobtrusive to both the user
> and the maintainer.


Moving the coupling between presentation and behaviour to your JavaScript is
no easier to maintain (or harder).  The benefits are generally academic.
*Except* for generic scripts that are designed for easy reuse, but most
scripts depend on some form of hook into the markup.

-- LK



More information about the thelist mailing list