Java Tutorial/JSP/Form TextField
Версия от 17:44, 31 мая 2010; (обсуждение)
Insert Text To Form TextField
index.jsp
<HTML>
<HEAD>
<TITLE>Inserting Text into Text Fields</TITLE>
</HEAD>
<BODY>
<H1>Inserting Text into Text Fields</H1>
<FORM NAME="form1" ACTION="basic.jsp" METHOD="POST">
<INPUT TYPE="TEXT">
<INPUT TYPE="SUBMIT" VALUE="Click Me!">
</FORM>
</BODY>
</HTML>
Read value in Form TextField using JSP
index.jsp
<HTML>
<HEAD>
<TITLE>Submitting Text Fields</TITLE>
</HEAD>
<BODY>
<H1>Submitting Text Fields</H1>
<FORM ACTION="basic.jsp" METHOD="POST">
Please enter your name:
<INPUT TYPE="TEXT" NAME="text1">
<BR>
<INPUT TYPE="SUBMIT" value="Submit">
</FORM>
</BODY>
<HTML>