• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

js code needed !

 
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi all,

i need a javascript code snippet to check if the values entered in two subsequent textboxes are the same. if they are the same i need to display an alert ...

and also i m in need of a session invalidate code... as i m new to programming... plz tel me the exact way in wich i hav to include the code in my program..

thanx in advance.
 
Ranch Hand
Posts: 1704
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Arya Devan:
hi all,

i need a javascript code snippet to check if the values entered in two subsequent textboxes are the same. if they are the same i need to display an alert ...

and also i m in need of a session invalidate code... as i m new to programming... plz tel me the exact way in wich i hav to include the code in my program..

thanx in advance.



Is the text boxes are random text boxes, i mean you do not know the text boxes names. If you know the text boxes names your job is easier.

Code looks like this:

if(formname.textbox1.value == formname.textbox2.value) {
alert("both textbox1 and textbox2 contents are equal);
}
 
Arya Devan
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanx reddy,

i do know the names of text boxes... but then... i m using




it gives me and error.. i dunno y....

plz help....

thanks again for the reply...
 
reply
    Bookmark Topic Watch Topic
  • New Topic