This week's book giveaway is in the Java in General forum.
We're giving away four copies of Event Streams in Action and have Alexander Dean & Valentin Crettaz on-line!
See this thread for details.
Win a copy of Event Streams in Action this week in the Java in General forum!
  • 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
  • Devaka Cooray
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Paul Clapham
  • Knute Snortum
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Ron McLeod
  • Piet Souris
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Frits Walraven
  • Ganesh Patekar

Action problem

 
Ranch Hand
Posts: 834
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Type : ActionForm
Name : TestForm




Type : Action
Name : Testing





hi, good day, i having a problem in action, which as shown on top source code, my problem is if i do not type any character in email textfield, it still calling the "success", can any GURU here please point out my mistake ? thank you very much !!
[ August 23, 2004: Message edited by: Alvin chew ]
 
pie sneak
Posts: 4727
Mac VI Editor Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
an empty textfield submission calls setEmail("")

email is then set to ""

so the getEmail is returning ""

your check is for null, not "" (empty String)
 
Alvin chew
Ranch Hand
Posts: 834
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thank you marc !!
 
Alvin chew
Ranch Hand
Posts: 834
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
another problem which now cause actionmapping or actionform collection problem ..

struts-config.xml - formbean part


struts-config.xml - actionmapping part


action class
 
Alvin chew
Ranch Hand
Posts: 834
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
actionform



html form
 
Alvin chew
Ranch Hand
Posts: 834
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
as mentioned, i found the actionmapping or actionform collection error, i check the error for many times, still can't figure out what problem is it ...as a newbie in struts, i would like to say thank you again for your time and your advice !!
 
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You haven't actually described what the problem is. What error are you getting?

Andy
 
Alvin chew
Ranch Hand
Posts: 834
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi, andy, thank for viewing, my tomcat show me the "actionmapping or actionform collection error"
 
Alvin chew
Ranch Hand
Posts: 834
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
to further describe, my problem is actually , the jsp page that suppose to display form but some how it couldn't display out but generate the error
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!