Re: accessing a script's tag (and attributes)



The idea is to simplify AJAX by component-izing functionality. The
custom properties on the script tag would make it easier for HTML
designers to include functionality on the page. Events and methods
would still be handled in javascript.

Of course, you could make the entire page from javascript but I don't
think the designers would like that very much.

HTML Components (HTCs) is a W3C suggestion from MS that is similar (you
can wrap them in wrappers for Mozilla XBL -
http://dean.edwards.name/moz-behaviors/) but the net result is that it
is still too complicated for many people. Even if it's not too
complicated for you, it seems like too much work to find a few
time-savers. Also, I prefer pure javascript.

In HTCs favour, they posess the 'element' property inside an HTC that
allows you access to the containing HTC tag (along with many other cool
features). Dave Edwards (the fellow who created the moz-behaviours XBL
wrappers for HTC) was also able to represent the 'element' property
along with support for most of the other features.

Rein

.



Relevant Pages

  • Using HTCs in design mode
    ... I noticed that when I load a HTML document that contains HTML ... Components (HTCs) into IE6, that the HTC elements disappear if I ... could this cause HTC to not render? ...
    (microsoft.public.inetsdk.programming.webbrowser_ctl)
  • XP SP2 and HTCs in webbrowser control
    ... The page that attempts to load the HTC is generated by loading "about:blank" ... If I write the HTML page to disk and then use Navigate2to load it from ... it loads and executes the Javascript in the HTC. ...
    (microsoft.public.inetsdk.programming.webbrowser_ctl)