• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

validation for each button

 
prathimaprasun rao
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello everyone,
I have three fields namely - sno, sname and class.

sno and sname are the text fields where as class is a list box with values from 1 to 10.

i have four buttons below these three fields.They are Add, Modify, Update and Remove.

there is a text area below these four buttons.

when i enter data into those three fields and click add, all the data will be displayed in the text area.when i select data from that text area and click modify the data will be populated from the textarea into the corresponding fields.when i click update, the data from those fields will be vanished and the fields will be empty.

now i need to write a validation so that these fields are not blank and display an alert whenever i click add or update buttons.

input type="button" value="Add" onClick
input type="button" value="Modify" onClick
input type="button" value="Update" onClick
input type="button" value="Remove" onClick

I think i need to write the logic for this validation below the value ="add" and value ="Update".
[ July 23, 2007: Message edited by: Bear Bibeault ]
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64959
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Regd:validation for each button

Please use only real words when posting to the forums. "regd" is not a word, and I have no idea what is intended to mean.

Please read this for more information.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64959
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there a server round-trip that occurs whenever one of these buttons is pressed, or is all this happening on the client?
 
prathimaprasun rao
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
All this is happening at the client side.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64959
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Then you'll need to handle all of this in JavaScript. This post is appropriately moved.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic