1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145
| <?
include("menu1.php");
include("configbase.php");
$pays=$_GET['pays'];
$id_soc = $_GET["id_soc"];
$ville = $_GET['ville'];
$soc_org = $_GET['soc_org'];
$ser_lab = $_GET['ser_lab'];
$cp = $_GET['cp'];
$tel = $_GET['tel'];
$fax = $_GET['fax'];
$id = $_GET['id'];
$id_cmd = $_GET['id_cmd'];
$type = $_GET['type'];
$id_cmd_pdt = $_GET["id_cmd_pdt"];
$req1 = "SELECT * FROM societe, pays where societe.id=$id_soc and societe.id_pays = pays.id";
$res1 = mysql_query($req1);
$row1 = mysql_fetch_assoc($res1);
$code_soc = $row1['code_soc'];
$req2 = "SELECT * FROM contact where id=$id";
$res2 = mysql_query($req2);
$row2 = mysql_fetch_assoc($res2);
$req4 = "select *
from commande
where id_command = $id_cmd";
$res4 = mysql_query($req4);
$row4 = mysql_fetch_assoc($res4);
$langue = $row4["lang"];
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"
"http://www.w3.org/TR/PR-html40/strict.dtd">
<html>
<HEAD>
<TITLE>ADHESION GAZETTE LABORATOIRE</TITLE>
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">
<style>
b { font-size:12px; font-family:"Courier New", Courier, monospace; font-weight: bold; color:#OO60c0}
h3 { font-family:"Courier New", Courier, monospace; font-weight: bold; color:#OO60c0}
A:link {
COLOR: #336699;
FONT-FAMILY: Verdana, Helvetica;
FONT-SIZE: 10pt;
text-decoration: none;
}
A:visited {
COLOR: #336699;
FONT-FAMILY: Verdana, Helvetica;
FONT-SIZE: 10pt;
text-decoration: none;
}
A:active { COLOR: ###336699;
FONT-FAMILY: Verdana, Helvetica;
FONT-SIZE: 10pt;
text-decoration: none;
color: #336699;
}
A:hover {
COLOR: #c8373a;
FONT-SIZE: 10pt;
text-decoration: none;
}
</style>
<SCRIPT language="JavaScript">
<!--
//-->
</script>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"></HEAD>
<BODY BGCOLOR="#AODOFF" TEXT="#OO60c0">
<br><br><br><br>
<table border="0" width="99%">
<tr>
<td width="80%" ALIGN="right">
<A href="commander_suite_form.php?id_soc=<? echo $id_soc?>&pays=<? echo $pays?>&soc_org=<? echo $soc_org?>&ser_lab=<? echo $ser_lab?>&ville=<? echo $ville?>&cp=<? echo $cp?>&tel=<? echo $tel?>&fax=<? echo $fax?>&id=<? echo $id?>&id_cmd=<? echo $id_cmd?>&type=<? echo $type?>&id_cmd_pdt=<? echo $id_cmd_pdt?>" LINK="#OO60c0"><b>Retour</b></A>
</td></tr>
</table>
<table width="80%" border align="center" cellpadding=5 cellspacing=0 bordercolor="#AODOFF" bgcolor="white">
<tr>
<th width="20%">Code Société</th>
<th width="38%">Société/Organisme</th>
<th width="30%">Contact</th>
</tr>
<tr>
<td> <? echo $row1['code_soc']?></td>
<td> <? echo $row1['soc_org']." ".$row1['soc_org2']?></td>
<td> <? echo $row2['titre']." ".$row2['nom']." ".$row2['prenom']?></td>
</tr>
</table><br>
<table width="60%" border=0 align="center" cellpadding=7 cellspacing=0 bordercolor="#AODOFF" bgcolor="white">
<tr>
<th align="center">DATES DE PARUTION</th>
</tr>
</table><br>
<?
//Définition des date au format jour-mois-année
$date_today = date("d-m-Y");
$f = date ( "d-m-Y" , mktime ( 0 , 0 , 0 , 12 , 31 , date("Y") ) ) ;
//Extraction des données
list($jour1, $mois1, $annee1) = explode('-', $f);
list($jour2, $mois2, $annee2) = explode('-', $date_today);
//Calcul des timestamp
$timestamp1 = mktime(0,0,0,$mois1,$jour1,$annee1);
$timestamp2 = mktime(0,0,0,$mois2,$jour2,$annee2);
$a = number_format(abs($timestamp2 - $timestamp1)/(86400*7*4));
$c = $a/4;
$k = 1;
?>
<form name="form1" method="post"
action="passer_commande5.php?id_soc=<? echo $id_soc?>&pays=<? echo $pays?>&soc_org=<? echo $soc_org?>&ser_lab=<? echo $ser_lab?>&ville=<? echo $ville?>&cp=<? echo $cp?>&tel=<? echo $tel?>&fax=<? echo $fax?>&id=<? echo $id?>&id_cmd=<? echo $id_cmd?>&type=<? echo $type?>&id_cmd_pdt=<? echo $id_cmd_pdt?>">
<table width="90%" border=1 align="center" cellpadding=7 cellspacing=0 bordercolor="#AODOFF" bgcolor="white">
<tr>
<?
for($j=1;$j<$c;$j++)
{
for($i=$k;$i<$k+4;$i++)
{
?>
<th align="center" width="7%"> <input name="date[]" type="checkbox" value="<? echo date('d-m-Y', mktime ( 0 , 0 , 0 , (date('m')+$i) , 1 , date('Y') ) )?>"><? echo date('d-m-Y', mktime ( 0 , 0 , 0 , (date('m')+$i) , 1 , date('Y') ) ) ;?> <input type="text" name="nombre[]" size="5"></th>
<?
}
?>
</tr>
<?
$k = $k + 4;
}
?>
<tr>
<?
for($m=$i;$m<$i+($a-$k);$m++)
{
?>
<th align="center" width="7%"> <input name="date[]" type="checkbox" value="<? echo date ( 'd-m-Y' , mktime ( 0 , 0 , 0 , (date('m')+$m) , 1 , date('Y') ) ) ;?>"><? echo date ( 'd-m-Y' , mktime ( 0 , 0 , 0 , (date('m')+$m) , 1 , date('Y') ) ) ;?> <input type="text" name="nombre[]" size="5"></th>
<?
}
?></tr>
<tr>
<th align="center" colspan="4"><input type="submit" name="Submit" value="Envoyer"></th>
</tr>
</table>
</form>
</body>
</html> |