Home >Java >javaTutorial >How to align text boxes in jsp
Here we use a table to align the text of the Jsp page with the text box.
border="0" cellpadding="0" cellspacing="20",
The first parameter is to set the page margin to 0, and the second parameter is used to specify the size of the blank distance between the cell content and the cell boundary. , the third parameter is the margin of 20 (that is, the spacing between lines)
Please see the example below:
<div id="tt" class="easyui-tabs"> <div title="基本信息"> <table align = "center" border="0" cellpadding="0" cellspacing="20"><!-- cellspacing="80"这个是外间距, --> <tr> <td>账号:</td> <td><input type="text" name="account" id="Account" /><span id="er"></span> <label for="Account"></label></td> </tr> </br> <tr> <td>密码:</td> <td><input type="text" name="Password" id="Password" /> <label for="Password"></label></td> </tr> <tr> <td>请再输入一次密码:</td> <td><input type="text" name="Enter_the_password_again" id="Enter_the_password_again" /> <label for="Enter_the_password_again"></label></td> </tr> <tr> <td>常用手机号码:</td> <td><input type="text" name="Phonenumber" id="Phonenumber" /> <label for="Phonenumber"></label></td> </tr> <tr> <td>真实姓名:</td> <td><input type="text" name="Realname" /></td> </tr> <tr> <td>身份证号码:</td> <td><input type="text" name="Idcardnumber" /></td> </tr> <tr> <td>代理地区:</td> <td><select id="Province" name="Province"></select> <select id="City" name="City"></select> <select id="Area" name="Area"></select> <script type="text/javascript"> addressInit('Province', 'City', 'Area'); </script></td> </tr> <tr> <td>公司名称:</td> <td><input type="text" name="Nameofcompany" /></td> </tr> <tr> <td>推荐人ID:</td> <td><input type="text" name="Referees" /></td> </tr> <tr> <td>代理法人照片(手持身份证):</td> <td><input type="file" id="file1" name="Photoagencyasalegalperson" /> </td> </tr> <tr> <td>营业执照:</td> <td><input type="file" id="file2" name="Thebusinesslicense" /> </td> </tr> <tr> <td>营业执照副本:</td> <td><input type="file" id="file3" name="Duplicateofbusinesslicense" /> </td> </tr> <tr> <td>银行开户许可证:</td> <td><input type="file" id="file4" name="Thebankopensanaccountlicence" /> </td> </tr> <tr> <td>父级代理ID:</td> <td><input type="text" name="Pid" /></td> </tr> </tr> </table> </div> </div>
The above is the detailed content of How to align text boxes in jsp. For more information, please follow other related articles on the PHP Chinese website!