i have 3 buttons 'add','update,'delete' in my jsp what i want is depending on the button name i am trying to do the actoin.
Below i have given my function -----> field i will get my "Button Name"...
My question is how can i send a button name just like a parameter to servlet?
like for ex:
"../Customer?field.name" <--------- is this possible i am getting error is any other ways?
Expand|Select|Wrap|Line Numbers
- function CustAction(field){
- var name=field.name;
- var FieldName = document.forms[0].PassportNo.value;
- document.forms[0].method="Post";
- document.forms[0].action="../Customer";
- document.forms[0].submit();
- }
any kind of help is greatful.
Ajay.