PHP-Code:
	
	
include('connect.php');
if($_POST[suchen])
{ 
$tb_name="fertigungsauftrag";
error_reporting(E_ALL);
$sql = "select FA_NR, Menge from $tb_name where FA_NR = '" . $_POST['FA_NR'] . "'";
$result = mysql_query ($sql, $link) or die ("MySQL-Fehler: " . mysql_error());
while ($row = mysql_fetch_array($result))
echo $row['FA_NR'] . $row['Menge'];
echo '<table width="20%" align="center" border="2" bgcolor="FFFF68" frame="box" rules="none" bordercolor="FFFFF">
      <caption><h1>Fertigungsauftrag</h1></caption>
      <form action="'.$PHP_SELF.'" method="post" >
        <tr><td>FA-Nr.</td>
        <td>Menge</td>
        <td>Auswahl</td>
        </tr>
        <tr>
        <td><input type="text" name="FA_NR" value="'.$_POST['FA_NR'].'"> </td>
        <td><input type="text" name="Menge" value="1"> </td>
        <td><input type="checkbox" name="checkbox"> </td>
        </tr>
        <tr>
        <td><input type="submit" name="bearbeiten" value="bearbeiten"></td>
        </tr>
      </form>
</table>';
  
}
else {
?>
<table width="20%" align="center" border="2" bgcolor="FFFF68" frame="box" rules="none" bordercolor="FFFFF">
      <caption><h1>Fertigungsauftrag</h1></caption>
      <form action="<? $PHP_SELF ?>" method="post" >
        <tr><td>FA-Nr.</td>
        </tr>
        <tr>
        <td><input type="text" name="FA_NR"></td>
        </tr>
        <tr>
        <td><input type="submit" name="suchen" value="suchen"></td>
        </tr>
      </form>
</table> <?}?>;
 
          
 Eventuell habe ich heute Abend Zeit, mir das nochmal anzusehen. Aber bis dahin wird das Problem wohl schon gelöst sein.
 Eventuell habe ich heute Abend Zeit, mir das nochmal anzusehen. Aber bis dahin wird das Problem wohl schon gelöst sein.
Kommentar