how to get value in javascript for using in code java

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • samds
    New Member
    • Apr 2015
    • 8

    how to get value in javascript for using in code java

    hi
    how to get value in javascript for using in code java in (jsp)
    thanks :)
  • Dormilich
    Recognized Expert Expert
    • Aug 2008
    • 8694

    #2
    please explain.

    Comment

    • samds
      New Member
      • Apr 2015
      • 8

      #3
      i want to get value into javascript for using in code java
      exemple :
      Code:
      <input type="texte" id="value" />
      <script>
      var a=document.getElementById("value").value();
      </script>
      <% Resulest rs=st.executeQuery("select * from employees where employe_id="+a);%>
      but i want to get value (a) for using into query
      Last edited by gits; Apr 27 '15, 12:58 PM.

      Comment

      • Dormilich
        Recognized Expert Expert
        • Aug 2008
        • 8694

        #4
        you can’t do it this way.

        you’ll have to send it via HTTP (form submit or AJAX) over for JSP to use it.

        Comment

        • samds
          New Member
          • Apr 2015
          • 8

          #5
          give me example plzz

          Comment

          Working...