PDA

View Full Version : How to call the javascript function??


CoraLover
06-17-2003, 08:42 AM
Hi, do u think that the below scenario can be done??

Scenario->

Page1.jsp contains a javascript called func1();

Page2.jsp contains a javascript called func2();

How does Page2.jsp call the javascript, func1() in Page1.jsp???

Both of the files are contained @ 2 different location...

Skyzyx
06-17-2003, 09:18 AM
If the script is not page-dependent, you can place the script (without the <script> tags) within a JavaScript Library (*.js). You can then include the library in both pages, and call the function from either page.

CoraLover
06-17-2003, 04:01 PM
Hi Skyzyx, i wanna say "Thank U so, so, so~~ much!!" U have solved my trouble which has been bugging me for the whole day. Really grateful!