onload function required for multiple tiles in a single form
eric he
Greenhorn
Joined: Mar 15, 2005
Posts: 6
posted
0
I have multiple tiles, each of them requires enable/disable some controls when the form is initially loaded, they are used together inside a single form of a generic layout jsp, which I can't modify, anybody knows how to make it work?
Thanks in advance.
Eric
Merrill Higginson
Ranch Hand
Joined: Feb 15, 2005
Posts: 4864
posted
0
Just put the enable/disable code in a <script></script> tag set at the bottom of your HTML in each page. I'm not talking about writing a function, I'm talking about just writing lines of JavaScript code that will run when the page is rendered. This will have the same effect as having it executed by the body's onload event.
Thanks Merrill, your suggestion worked, it seems have the same effect as putting a function call inside form.onload.
Eric
eric he
Greenhorn
Joined: Mar 15, 2005
Posts: 6
posted
0
more interesting question would be, what if I want to do something on form.reset, suppose I know the form.onreset for the layout is empty, and I have resetTile1, resetTile2 on two different tiles, is there any javascript solution to do that without changing the layout? this should be a common tiles question.