<?

include("dblib.inc");

include("clublib.inc");

checkAdmin();

$message = "";

?>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">



<html>

<head>

	<title>Gestione Ordini da Catalogo</title>

	<link rel="stylesheet" type="text/css" href="stylesheet.css">

</head>



<body bgcolor="#FFFFFF" link="#504C43" alink="#000000" vlink="#504C43" text="#000000">

<? 

   include("Header.php"); 


 
include ("langselect.php");





$cliente = getRow($customers_table, "Ragione_Sociale", $form['Ragione_Sociale']);

		echo"<p><a href=\"Admin_faiordine.php?form[ID_Cliente]=$cliente[ID_Cliente]\">Cataloghi Cliente $cliente[Ragione_Sociale]</a> | 
<a href=\"clgestord.php?form[Ragione_Sociale]=$cliente[Ragione_Sociale]\">$lang0005</a> 
<p>$lang0029</p>";
 


include ("config18.php"); 
mysql_connect("$hhost","$login","$pass") or die ("Problem connecting to DataBase"); 
$query = "SELECT * FROM $connect "; 
$result = mysql_db_query("$dbname", $query); 
if ($result) {
while ($r = mysql_fetch_array($result)) {
$imgpicc = $r["imgpicc"];
$imggra = $r["imggra"];
$quant = $r["quant"];
$oggnom = $r["oggnom"];
$prezog = $r["prezog"];
$periva = $r["periva"];
$descrogg = $r["descrogg"];
  
echo "<form method=post action=\"regorder.php?form[Ragione_Sociale]=$cliente[Ragione_Sociale]\" name=pws_clienti>

<!-- flag di invio del modulo -->

<input type=Hidden name=actionflag value=insert>

<input type=Hidden name=form[Status] value=\"PAYPAL\">



<table width=100% height=102 border=1 align=center cellpadding=1 cellspacing=0>

 <input type=hidden name=form[Ragione_Sociale] value=\"$cliente[Ragione_Sociale]\">

  
  <td width=120 >$oggnom<input type=hidden name=form[Oggetto] value=\"$oggnom\" ><a href=\"/#\" onclick=\"window.open('$imggra','clock','scrollbars=yes,width=300,height=300,left='+(screen.availWidth/2-150)+',top='+(screen.availHeight/2-150)+'');return false;\"><img style=\"width: 150px; height: 112px\" height=112 src=$imgpicc width=150 border=0 /></a></td>
  <td width=130 >$descrogg</td> 

    <td width=130 ><p>$lang0030 $quant</p></td>

    <td width=56 ><input type=text name=form[Protocollo]  value=1 maxlength=6 size=6>&nbsp;</td>
    <input type=hidden name=form[Tipo_Pagamento] value=nd>
	
    <td width=159 ><input type=text name=form[Prezzo] maxlength=8 size=8 value=\"$prezog\"  >
 $lang0150 </td>
	 
     <input type=hidden name=form[Iva] value=$periva>
	 <input type=hidden name=connect value=$connect>
	 <input type=hidden name=oggnom value=$oggnom>
	 <input type=hidden name=form[Cat_Ogg] value=$connect>
	
		 
  <td width=67 colspan=2 align=right nowrap >
	  

      <!-- BEGIN Button Insert --><input name=Insert type=submit value=\"$lang0031\" ><!-- END Button Insert -->

</td>

</table>

</form>";
} 
 
} 
?>
</body>
</html>