How to print updated form "hidden" field value without refreshing the page/jsp.
posted 6 years ago
I need suggestion on how to print the updated form "hidde" field value on JSP screen without refreshing the page. (server side I'm using Struts)
Currently I'm printing one form hidden field as
Here on pageload I have to check some results based on I have to increment this counter on the fly and display.
I tried using Ajax I sent request on pageload and updated this "testCounter" value on server side but I stuck to get the results back immediately with "updated form hidden field value" to print on the jsp.
When I searched in Google all i found is
- to submit the form using AJAX whithout refreshing the page and getting the results back as simple text printing on the screen as "Thank you for visiting" etc...
Could any one please help me ASAP to get Ajax response with updated form field values to print on JSP immediately without refreshing the page, or any solution other than AJAX in this case.
any advice and/or sample code will be greatly appreciated. thank you.