开发者

How can I make my HTML table rows editable using PHP? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.

Want to improve this question? Update the question so it focuses on one problem only by editing this post.

Closed 5 hours ago.

开发者_Python百科 Improve this question

I can't seem to edit my table rows using PHP. I'm new to this language so I'm having some trouble.

I have created a table with rows using PHP. The data inside my rows is created by fetching my database MySql table. I want to allow the user to edit information for each row. I'm not sure how to do this in PHP.

Below is my PHP code:

  echo "<table border='1'>
      <tr>
      <th>Job ID:</th>
      <th>Job Title:</th>
      <th>Min Salary:</th>
      <th>Max Salary:</th>
      </tr>";

      while($row = mysqli_fetch_array($result))
      {
      echo "<tr>";
      echo "<td>" . $row['job_id'] . "</td>";
      echo "<td>" . $row['job_title'] . "</td>";
      echo "<td>" . $row['min_salary'] . "</td>";
      echo "<td>" . $row['max_salary'] . "</td>";
      echo "</tr>";
      }
      echo "</table>";

          mysqli_close($conn);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜