Win a copy of Head First Android this week in the Android 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Rob Spoor
  • Devaka Cooray
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
  • Tim Holloway
Bartenders:
  • Jj Roberts
  • Al Hobbs
  • Piet Souris

How to get Form Name using TexyBox name

 
Ranch Hand
Posts: 97
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello everyone,
i want to that How to get Form Name using TexyBox name.
suppose in 1 jsp page i have created 3 forms
In 1 of the forms i have included common.jsp file
now in that common.jsp file there is an textBox name Go.

what i want is Using that Go button i want to know the Action name and the Form name..
jsp will look something like this:
test.jsp-------------------------
< html form name=... action=...... >
.
.
.
< / html form >
< html form name=test action=test >
.
< input type.... name= Go value=... / >
.
< / html form >

< html form name=... action=...... >
.
.
.
< / html form >
On Click of Go what i want is that Action is ... and formname is ..... where
textbox name is GO..

i hope i am clear

thanks,
Nishita
 
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
call the following function on click of the go button by passing an instance of textbox.

function getFormName(obj){
var formObj=obj.form;

alert(formObj.name);
alert(formObj.action);
}


Hope I got your question correct
 
Nishita Jain
Ranch Hand
Posts: 97
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hello Kamesh
tahnks for the prompt reply.
but thing is that whta if there is a link instead of that button..
i want form name in Link. i m sorry i forgot to mension that

thanks,
Nishita
[ December 28, 2006: Message edited by: Nishita Jain ]
 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic