<?php if (isset($_POST{"update"}) == "true") { include "db.php"; $id=$_GET{"nid"}; $update=mysql_query("SELECT * FROM news WHERE nid='$id'") or die(mysql_error()); while($row=mysql_fetch_array($update)){ echo "<html>"; echo "<head>"; echo "</head>"; echo "<body>"; echo "<input style=\"width: 300px\" type=\"text\" name=\"upd_sub\" value=".$row{'subject'}."/>"; echo "<br>"; echo "<input type=\"text\" name=\"upd_rep\" value=".$row{'reporter'}."/>"; echo "<br>"; echo "<textarea cols=\"45\" rows=\"25\" name=\"upd_con\" value=".$row{'content'}."/>"; echo "</body></html>"; } // while } ?>
|