• Post Reply Bookmark Topic Watch Topic
  • New Topic

how to get a value of field form on same jsp page

 
alsoumahi alBatal
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi guys , I am having simple problem , I need to get a value of field form on same page , and based on it I will do some process using java code on same page
I know that to read a value , I can use java script using getByElement , but how then I use this value with my java code

thanks a lot
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65530
108
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can't.

The Java code in your JSP (really? you're putting Java code in a JSP? ) executes on the server in order to format the HTML page with the JavaScript to send to the browser. The user enters the form field on the client. How could it interact with the Java code that executed before the page was even sent to the browser?

Please read this article to understand how JSP operates.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!