myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vladimir Isakovich" <>
Subject Re: How to call a java script method when the form is loading...
Date Fri, 06 Jul 2007 14:40:57 GMT
First you should read about javaScript. Just google and find a sutable link.
onLoad event may be accessed from <body > tag only.
Actually, there are two ways to call js function on load.
1. - the most legit - usin onLoad event as you tried but from a wrong tag
2. - just call your function from the open script between <script> tags -
this way there is no garantee if your page has already being loaded, you may
even experiment placing this call before and after the /body or even after
the </html> - this is not recomended if you're going to refer to some
element of your document - there is always a question if it has beeen
rendered at the time.


On 7/6/07, <>
>  Hi,
>                 How to call a java script method when the page is loading
> using <h:form>.
> Actually we have onLoad event for <body> tag in html. I tried this event
> for <h:form>. But its not working.
> Can anybody tell me how to call a java script method when my form is
> loading?
> Regards,
> Basha
> The information contained in this electronic message and any attachments
> to this message are intended for the exclusive use of the addressee(s) and
> may contain proprietary, confidential or privileged information. If you are
> not the intended recipient, you should not disseminate, distribute or copy
> this e-mail. Please notify the sender immediately and destroy all copies of
> this message and any attachments.
> WARNING: Computer viruses can be transmitted via email. The recipient
> should check this email and any attachments for the presence of viruses. The
> company accepts no liability for any damage caused by any virus transmitted
> by this email.

View raw message