please try click() instead of onclick()

On 10/26/06, Peter Beshai <[EMAIL PROTECTED]> wrote:

Is there an easy way of calling a listener after the page appears
(rendered)
on screen? I couldn't think of one, and so I tried having adding an event
to
the onload of the page:

<script type="text/javascript">
dojo.event.connect(window, "onload",dojo.byId("mockHidden").onclick());
</script>

or

<script type="text/javascript">
dojo.addOnLoad(function(e){ dojo.byId("mockHidden").onclick() });
</script>

where mockHidden is a component that has an eventlistener (the listener I
want to have called after the page is loaded) attached to it in my .java
file. If I call dojo.byId("mockHidden").onclick() from firebug's console,
it
works, but when the page loads it says :: dojo.byId("mockHidden").onclick
is
not a function.

I figured that was because tapestry connects the event at the end of the
page (and that <script> block is somewhere before that). Is there any way
of
having the javascript called AFTER tapestry has connected the event?? Or
is
there another way of accomplishing this goal?

Thanks,
Peter Beshai

_________________________________________________________________
Voyez vos amis en faisant un appel vidèo dans Windows Live Messenger
http://imagine-msn.com/messenger/launch80/default.aspx?locale=fr-ca


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




--
Thanks, Karthik

Reply via email to