how to refer a textbox inside body of html page in a javascript if textbox is not part of any form?

StackOverflow https://stackoverflow.com/questions/1399410

  •  22-09-2019
  •  | 
  •  

Question

i have coded a header file which contains a input textbox for search.this header is include in body tag of a jsp page as shown below.

<body>
<include src="header.ssi">
<form>
</form>

onclick of button i header file i am running a javascript function. i need to refer to this textbox in javascript function.

Was it helpful?

OTHER TIPS

If you can use jQuery then simply use $("#textboxid") to access the textbox

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top