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
|
<?php
session_start();
error_reporting(0);
header("Content-type: application/vnd.ms-excel");
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr">
<head>
<meta http-equiv=Content-Type content="text/html; charset=utf-8" />
<meta http-equiv="Content-Language" content="fr" />
<?php
$log=$_SESSION['log'];
include('connection.php');
?>
<table border="0" bgcolor='#999999' style="width:100%">
<tr><th width="6%" bgcolor="#9999FF"><font size="-1">nom</font></th>
<th width="15%" bgcolor="#9999FF"><font size="-1">prenom</font></th>
<th width="21%" bgcolor="#9999FF"><font size="-1">contact</font></th>
<th width="19%" bgcolor="#9999FF"><font size="-1">adresse</font></th>
<th width="6%" bgcolor="#9999FF"><font size="-1">Code Postal</font></th>
<th width="20%" bgcolor="#9999FF"><font size="-1">ville</font></th>
<th width="4%" bgcolor="#9999FF"><font size="-1">publicitaire</font></th>
<th width="3%" bgcolor="#9999FF"><font size="-1">invitation</font></th>
<th width="3%" bgcolor="#9999FF"><font size="-1">VIP</font></th>
<th width="3%" bgcolor="#9999FF"><font size="-1">carte</font></th>
<th width="3%" bgcolor="#9999FF"><font size="-1">billeterie</font></th>
</tr><?php
$total="";
$_SESSION['req']='SELECT c.*,s.* FROM clients c inner JOIN service s ON c.id=s.id_user where 1';
if($_POST['publicitaire']=='on')
{
$_SESSION['req'].=" AND s.publicitaire='1' ";
$total.="/ publicitaire /";
}
if($_POST['invitation']=='on')
{
$_SESSION['req'].=" AND s.invitation='1' ";
$total.="/ invitation /";
}
if($_POST['VIP']=='on')
{
$_SESSION['req'].=" AND s.vip='1' ";
$total.="/ VIP /";
}
if($_POST['carte']=='on')
{
$_SESSION['req'].=" AND s.voeux='1' ";
$total.="/ voeux /";
}
if($_POST['carte']=='on')
{
$_SESSION['req'].=" AND s.type_evenement ='billeterie' ";
$total.="/ billeterie /";
}
$resultat_total=mysql_query($_SESSION['req'])or die(mysql_error());
echo $total;
$num_res=mysql_num_rows($resultat_total);
if($num_res!='0')
{
$requy=$_SESSION['req'];
$resultat_sql=mysql_query($requy)or die(mysql_error());
while($b=mysql_fetch_array($resultat_sql ))
{
?><tr>
<td bgcolor="#FFFFFF" > <?php echo $b["nom"];?></td>
<td bgcolor="#FFFFFF"><?php echo $b["prenom"];?></font></td>
<td bgcolor="#FFFFFF"><?php echo $b["contact"];?></font></td>
<td bgcolor="#FFFFFF"><?php echo $b["adresse"];?></font></td>
<td bgcolor="#FFFFFF"><?php echo $b["code_postal"];?></font></td>
<td bgcolor="#FFFFFF"><?php echo $b["ville"];?></font></td>
<td bgcolor="#FFFFFF"><input type="checkbox" disabled="disabled" <?php if($b['publicitaire']==1){?> checked="checked"<?php };?> /></td>
<td bgcolor="#FFFFFF"><input type="checkbox" disabled="disabled" <?php if($b['invitation']==1){?> checked="checked"<?php };?> /></td>
<td bgcolor="#FFFFFF"><input type="checkbox" disabled="disabled" <?php if($b['vip']==1){?> checked="checked"<?php };?> /></td>
<td bgcolor="#FFFFFF"><input type="checkbox" disabled="disabled" <?php if($b['voeux']==1){?> checked="checked"<?php };?> /></td>
<td bgcolor="#FFFFFF"><input type="checkbox" disabled="disabled" <?php if($b['type_evenement']=='billeterie'){?> checked="checked"<?php };?> /></td></tr>
<?php
}
}
?></table> |