深圳网站建设哪家好?深圳做网站就找深圳乐道网络科技有限公司,乐道网络科技-专业的网站建设公司、网站建设工作室

News新闻

业界新闻动态、技术前沿
Who are we?

您的位置:首页      网站建设知识      Form提交表单页面不跳转

Form提交表单页面不跳转

1、设计源码

 

[html] view plaincopy在CODE上查看代码片派生到我的代码片
 
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">  
  2. <html xmlns="http://www.w3.org/1999/xhtml">  
  3. <head>  
  4. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />  
  5. <title>Form提交表单页面不跳转</title>  
  6. </head>  
  7.   
  8. <body>  
  9.    <form action="" id="" method="post" target="id_iframe">  
  10.         <input type="text" id="input_text" name="input_text"/>  
  11.         <input type="submit" id="sobmit" name="submit" value="提交" />  
  12.    </form>  
  13.    <iframe id="id_iframe" name="id_iframe" style="display:none;"></iframe>  
  14. </body>  
  15. </html>  


2、运行结果

 

(1)输入“451”,单击“提交”



(2)输入“45464646”,单击“提交”



页面提交刷新,不跳转