• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Junilu Lacar
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Knute Snortum
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Ron McLeod
  • Carey Brown
Bartenders:
  • Paweł Baczyński
  • Piet Souris
  • Vijitha Kumara

Moving static JavaScript validations into separate file

 
Ranch Hand
Posts: 172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I really suspect that moving static JavaScript validations into separate file really works in Struts? I've spent two nights trying to do that and failed. Is there any REAL WORKING EXAMPLE!!! I would like to see it!!!
 
Velika Srbija
Ranch Hand
Posts: 172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No idea???
 
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Take a look at the example below:

dcmsscripts.js -


visitation_othercustody.jsp -


Hope the above example gives you an idea how to implement static javascript validations within a separate .js file; such that it could be re-used over multiple .jsp pages.


Cheers,
Liju

PS- Parameter "on keypress" within the <html:text/> tag is actually one word.
[ April 13, 2006: Message edited by: Liju Cherian ]
 
Velika Srbija
Ranch Hand
Posts: 172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No, I don't want that!!!

In fact I have an example from the book, saying I should use dynamicJavascript and staticJavascript parameters of the html:javascript tag, but it doesn't work? I have found very simillar examples on the web, probbably transcribed from the books, but they doesn't work.
 
You're not going crazy. You're going sane in a crazy word. Find comfort in this tiny ad:
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!