尝试使用更新语句编辑后,数据库未更新


database not updating after attempting to edit with update statement

我的问题是这样的。我已经创建了一个从mysql数据库填充的表单。我希望能够编辑后,它已提交的形式。我已经得到了它的点,它将允许我编辑表单中的字段,但当我这样做的数据不是在数据库上更新。你能看看我的代码,看看我可能会出错吗?

<?php
  include_once 'includes/db_connect.php';
?>
</head>
    <body>
      <table cellpadding="0" cellspacing="0">
      <tr>
        <td class="headingsa7">Acceptance Criteria</td>
        <td class="headingsa8">Technician Responsible</td>
     </tr>
     <tr>
      <td class="headings1">Job/Order Number:</td>
      <td class="answerswers1"><div class= "typesection1">
      <?php echo ($row['job_order_number'] ); ?></div></td>
    <tr>
      <td class="answerswersa7">
        <div class= "typesectiona7">
          <?php 
             echo   ($row['acceptance_criteria1'] );
          ?>
        </div>
     </td>
     <td class="answerswersa8">
        <div class= "typesectiona8">
            <?php 
                echo($row['technician_responsible1'] ); 
             ?>
        </div></td>
   </tr>
  <tr>
   <td class="answerswersa7">
   <div class= "typesectiona7">
     <?
       php echo ($row['acceptance_criteria2'] );
     ?>
   </div></td>
   <td class="answerswersa8">
      <div class= "typesectiona8">
         <?php 
            echo ($row['technician_responsible2'] ); 
         ?>
      </div>
    </td>
 </tr>
 <tr>
   <td class="answerswersa7">
       <div class= "typesectiona7">
         <?php 
            echo ($row['acceptance_criteria3'] ); 
         ?>
       </div>
 </td>
 <td class="answerswersa8">
      <div class= "typesectiona8">
         <?php 
            echo ($row['technician_responsible3'] ); 
         ?>
       </div>
    </td>
 </tr>
 <tr>
     <td class="answerswersa7">
          <div class= "typesectiona7">
               <?php 
                  echo($row['acceptance_criteria4'] ); 
               ?>
          </div>
    </td>
  <td class="answerswersa8">
         <div class= "typesectiona8">
             <?php
                echo($row['technician_responsible4'] );
              ?>
         </div>
       </td>
    </tr>
  </table>
     <br /><br />
        <center> 
          <?php echo "<a href='"edit.php?  id=$row[job_order_number]'">Edit</a> |   <a href='"delete.php?id=$row[job_order_number]'" onClick='"return confirm('Are you sure you want to delete?')'">Delete</a> |
          ?>
       </center>
     </div>
    </body>
 </html>
编辑page.php

  </head>
       <body>
         <?php
                 mysql_connect("localhost","username","password");
                 mysql_select_db("joziweb1_form");
                 $order = "SELECT * FROM jobrequest";
                 $result = mysql_query($order);
                 $row = mysql_fetch_array($result);
           ?>
          <form method="post" action="edit_data.php">
               <table cellpadding="0" cellspacing="0">
                  <tr>
                     <td class="headingsa7">Acceptance Criteria</td>
                     <td class="headingsa8">Technician Responsible</td>
                  </tr>
                  <tr>
                     <td class="headings1">Job/Order Number:</td>
                     <td class="answerswers1">
                         <div class= "typesection1">
                            <?php 
                                echo $_GET['job_order_number'];
                             ?>
                          </div>
                     </td>
                 <tr>
                 <td class="answerswersa7">
                   <div class= "typesectiona7">
                          <?php 
                             echo ($row['acceptance_criteria1'] ); 
                          ?>
                   </div>
                 </td>
                  <td class="answerswersa8"><input class="typesectiona8" type="text" name="Technician_responsible1"value=<?php echo $technician_responsible1;?>> 
                 </td>
              </tr>
          <tr>
      <td class="answerswersa7">
            <div class= "typesectiona7">
                 <?php echo ($row['acceptance_criteria2'] ); ?>
            </div>
      </td>
    <td class="answerswersa8">

>

     <td class="answerswersa8">

>
>

Edit_data.php

    <?php 
       mysql_connect("localhost","username","password");
       mysql_select_db("databasename");           
       $order = "UPDATE jobrequest,
       SET technician_responsible1='$Technician_responsible1', technician_responsible2='$Technician_responsible2'                        technician_responsible3='$Technician_responsible3',                       technician_responsible4='$Technician_responsible4', 
       WHERE 'technician_responsible1' , 'technician_responsible2' , 'technician_responsible3' , 'technician_responsible4' , “;
      mysql_query($order);
      header("location:jobrequest_viewform.php");
  ?>

在edit.php页面添加以下代码

   session_start();
   $_SESSION['no']=$_GET['job_order_number'];

   session_start();
   $no=$_SESSION['no'];

然后使用

   $order = "UPDATE jobrequest,
   SET technician_responsible1='$Technician_responsible1',technician_responsible2='$Technician_responsible2',technician_responsible3='$Technician_responsible3',technician_responsible4='$Technician_responsible4', 
   WHERE job_order_number='$no'“;
  mysql_query($order);