Home > Backend Development > PHP Tutorial > How to build php form?

How to build php form?

怪我咯
Release: 2023-03-10 19:12:01
Original
3911 people have browsed it

Basic elements for building a form: form tag. The form tag is the most basic html tag to create a form. It starts with

Attached to you is an example

<form action="#" enctype="multipart/form-data" method="post" name="biaodan"  onsubmit="return comfirm()">
    
    <p class="bm_bt">     
     <p class="bm_bt1">姓名:<input type="text" name=&#39;names&#39; id=&#39;names&#39; class=&#39;intxt&#39; value=&#39;&#39;/>
    
       <span class="bm_s1">*请输入正确的联系方式  </span>
    
     </p>
    
     <p class="bm_bt1">电话:<input type="text" name=&#39;tels&#39; id=&#39;tels&#39; class=&#39;intxt&#39; value=&#39;&#39;/>
    
       <span class="bm_s1">*请输入正确的名字  </span>
    
     </p>
    
     <p class="bm_bt1">Q  Q:<input type="text" name=&#39;qqs&#39; id=&#39;qqs&#39; class=&#39;intxt&#39; value=&#39;&#39;/>
    
       <span class="bm_s1">请输入您的QQ号 </span>
    
     </p>
    
     <p class="bm_bt1">备注:<input type="text" name=&#39;others&#39; id=&#39;others&#39; class=&#39;intxt&#39; value=&#39;&#39;/>
    
       <span class="bm_s1">如有问题请留言</span>
    
     </p>
    
     <input type=&#39;text&#39; name=&#39;datas&#39; id=&#39;datas&#39; style=&#39;border:0 none; display:none;&#39;  class=&#39;intxt&#39; value=&#39;&#39; />
    
     <input type=&#39;text&#39; name=&#39;times&#39; id=&#39;times&#39; style=&#39;border:0 none; display:none;&#39;  class=&#39;intxt&#39; value=&#39;&#39; />
    
   </p>
    
   <p class="bm_ft">       
     <p class="bm_ft1"><input type="submit" name="submit" class=&#39;coolbg&#39; value=" "/>
    
    </p>
    
   </p>
    
   </form>
Copy after login

The above is the detailed content of How to build php form?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template