douliao1911 2014-03-24 07:58
浏览 7
已采纳

一个字段没有在php中提交值

        <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

its a complaint registration form.The created by field is not submitting its //value on on submit.

    <?php
//to display contents after posting in same page
    if (isset($_POST['submit'])) 
    {

    $createdby = $_POST["createdby"];

//its a complaint registration form.The created by field is not submitting its //value on on submit.

    echo "createdby:".$createdby." <br>";

    }

//its a complaint registration form.The created by field is not submitting its //value on on submit.

    echo "<script>window.close();</script>";

    ?> 



    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <link rel="stylesheet" type="text/css" href="../user.css"/>
    <title>User registration</title>


    //for validation

    <script src="jquery.js" type="text/javascript"></script>
     <script src="jquery.validate.js" type="text/javascript"></script>

     <script type="text/javascript">
     $(document).ready(function() {
             $("#usertype").validate();
     });

    //even date time picker is not working
     $(function() {
    $( "#datepicker" ).datepicker();
    });



     </script>
    </head>
    //its a complaint registration form.The created by field is not submitting its //value on on submit.
    <body>



    //the form containing the fields


    <form id="usertype" action="  " method="get" >
     <center>
     <h1> User Registration Page </h1>
     <div id="content">




         ***<ul class="user">
                    <li class="label">Created by</li>
                    <li class="field">
                     <input type="text" id="createdby" name"createdby" class="required error"/>
                     </li>
                    </ul>***

//submitting the form

        <input type="submit" name="submit" value="Submit"/>
        </div>
    </center>
    </form>
    </body>
    </html>

//its a complaint registration form.The created by field is not submitting its //value on on submit.strong text

  • 写回答

4条回答 默认 最新

  • duanbangzhou7809 2014-03-24 08:05
    关注

    You have a missing equal sign in name attribute of createdby field

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(3条)

报告相同问题?

悬赏问题

  • ¥15 微信小程序协议怎么写
  • ¥15 c语言怎么用printf(“\b \b”)与getch()实现黑框里写入与删除?
  • ¥20 怎么用dlib库的算法识别小麦病虫害
  • ¥15 华为ensp模拟器中S5700交换机在配置过程中老是反复重启
  • ¥15 java写代码遇到问题,求帮助
  • ¥15 uniapp uview http 如何实现统一的请求异常信息提示?
  • ¥15 有了解d3和topogram.js库的吗?有偿请教
  • ¥100 任意维数的K均值聚类
  • ¥15 stamps做sbas-insar,时序沉降图怎么画
  • ¥15 买了个传感器,根据商家发的代码和步骤使用但是代码报错了不会改,有没有人可以看看