<style type="text/css">
.style20 {
	font-family: Verdana;
	font-size: 12px;
}
.style5 {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 14px;
}
.style3 {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 13px;
}
.style10{ border-top:solid 1px; border-top-color:#999;}
.style11{ border-bottom:dashed 1px; border-bottom-color:#333333;}
.style4 {font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 13px;
}
.style23 {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-weight: bold;
}
.style27 {font-size: 12px}
.style28 {
	font-size: 16px;
	font-weight: bold;
}
.text {font-family: Verdana; font-size:13px;}
.style29 {	font-family: Verdana;
	font-size: 14px;
}
.stylebottom
{
	/*border-bottom:dashed;*/
	border-right:1px solid #999;
	
	border-bottom:1px solid #999;
}	

</style>
<div class="row-fluid">
<div class="span12">
<div class="table-responsive">
<div class="CSSTableGenerator">
<?php 
  include ("../../include/db.php");
error_reporting(0);
ob_start();
session_start();
 $session_branch=$_SESSION['branch'];
 $session_user_type=$_SESSION['user_type'];
 $cus_name=$_GET['customer_name'];

function get_categ_branch_id($branch_name)
{
$sql_query11="select * from branch_creation where branch_id='$branch_name' and delete_status!='1'";
$rs11=mysql_query($sql_query11);
 while($rsdata11=mysql_fetch_object($rs11))
 {
 $id=$rsdata11->branch_name;
 } 
	return $id;
 }
 $bran_name=get_categ_branch_id($branch_name);
if($session_user_type!=1)
{
 $query="select * from branch_creation  WHERE branch_id='$session_branch'";
}
$rs=mysql_query($query);						 
                                                $i=0;
                                                while($list=mysql_fetch_array($rs))
                                                {
                                                $i=$i+1;
												$branch_address=$list['branch_address'];
												$head_off=$list['head_off'];
												$branch_off=$list['branch_off'];
												$branch_ph=$list['branch_ph'];
												$delivery_ph=$list['delivery_ph'];
												$delivery_off=$list['delivery_off'];
											    }
											 ?>
<table width="850" height="51" border="0"  cellpadding="0" cellspacing="0" align="center">
<tr style="height:60">
<td width="137" height="106" align="right" style="font-size:12px; "><img src="../../img/logo_image.png" width="126" height="130"/></td>
<td width="711" colspan="5" align="center" valign="top" style=""><strong style="font-size: 30px; color: #06F; padding-top: 5px; width: 80px; font-family: Verdana, sans-serif">SRI AMMAN DIGITAL PRINTS</strong><br />
        <span width="80%" class="title1" style="font-size:14px;font-family:Verdana, sans-serif; font-weight:bold"><b></b> DOOR No: 1/2,1/3  KOMBAI THOTTAM MAIN ROAD,</span><br />
       <span width="80%" class="title0" style="font-size:14px;font-family:Verdana, sans-serif; font-weight:bold"><b></b>SELLANDIAMMAN THURAI ROAD,</span><br />
       <span width="80%" class="title0" style="font-size:14px;font-family:Verdana, sans-serif; font-weight:bold"><b></b>TIRUPPUR-641604 TAMILNADU STATE INDIA,</span><br/>
       <span width="80%" class="title00" style="font-size:14px;font-family:Verdana, sans-serif; font-weight:bold"><b></b>Contact Office: 0421-4355333,+91 83442-33555,+91 83442-33888,</span><br/>
       <span width="80%" class="title0" style="font-size:14px;font-family:Verdana, sans-serif; font-weight:bold"><b></b>Email Id : sriammandigitalprints@gmail.com/yahoo.com.</span><br/>
       <span width="80%" class="title0" style="font-size:14px;font-family:Verdana, sans-serif; font-weight:bold"><b></b>GSTIN : 33ADDFS1470L1Z1, PAN NO : ADDFS1470L.</span><br/>
    
    <span width="80%" class="title1" style="font-size:18px;font-family:Verdana, sans-serif; font-weight:bold"><b></b>Party Details List</span></p></td>
  </tr>
<tr>
<td width="171" height="25" align="left" class="style4"><strong>From Date :</strong>  <?php if($_GET['from_date']==''){ echo $curdate=date('d-m-Y');} else { echo date("d-m-Y",strtotime($_GET['from_date']));}?></td>
<td width="679" align="right" class="style4" scope="col"><strong>To Date :</strong>  <?php if($_GET['to_date']==''){ echo $curdate=date('d-m-Y');} else { echo date("d-m-Y",strtotime($_GET['to_date'])); }?></td>
</tr></table>

<table border="0" width="99%"  cellpadding="0" cellspacing="0"  >
      <tr>
      <td height="24" align="center" class="stylebottom style11 style10 style3" style="border-left:1px solid #999;" ><strong>S.No</strong></td>
      <td scope="col" align="left" class="stylebottom style11 style10 style3"><strong>&nbsp;Party Name</strong></td>
      <td scope="col" align="left" class="stylebottom style11 style10 style3"><strong>&nbsp;Mobile No</strong></td>
      <td scope="col" align="left" class="stylebottom style11 style10 style3"><strong>&nbsp;Phone No</strong></td>
      <td scope="col" align="left" class="stylebottom style11 style10 style3"><strong>&nbsp;E-mail ID</strong></td>
      <td width="205" align="left" scope="col" class="stylebottom style10 style11 style3"><strong>&nbsp;Address</strong></td>
      <td width="201" align="left" class="stylebottom style11 style10 style3"  scope="col"><strong>&nbsp;City</strong></td>
     
  </tr>
  <?php
include("../../include/db.php");
date_default_timezone_set('Asia/Kolkata');
$party_name=$_GET['party_name'];
$ph_no=explode('-',$party_name);
$customer=$ph_no[0];
$customer_no=$ph_no[1];

$party_name=$_GET['customer_name'];
if($party_name!='')
{	
 $sql="select * from  party_creation where  party_name='$party_name' and `party_type`='Customer' and delete_status!='1' and party_id!='' order by party_name asc "; 
}
else
{ 
 $sql="select * from  party_creation where delete_status!='1' and party_id!='' and `party_type`='Customer' order by party_name asc "; 
}
    $rs=mysql_query($sql);
	$sno=0;
   while($rsdata=mysql_fetch_array($rs))
  {
      $sno=$sno+1;
      $from=$from+1;
      $id=$rsdata['party_id'];
      $party_no=$rsdata['party_no'];
      $party_name=$rsdata['party_name'];
	  $mobile_no=$rsdata['mobile_no'];
	  $phone_no=$rsdata['phone_no'];
	  $email_id=$rsdata['email_id'];
	  $address=$rsdata['address'];
	  $city=$rsdata['city']; 
	  $create_date=$rsdata['create_date'];   
 ?>
  <tr>
    <td width="71" height="23"  align="center" class="style3 stylebottom" style="border-left:1px solid #999;"><?php echo $sno; ?></td>
    <td width="286" align="left" class="style3 stylebottom" >&nbsp;<?php echo ucfirst($party_name);?></td>
    <td width="158" align="left" class="style3 stylebottom" >&nbsp;<?php echo $mobile_no;?></td>
    <td width="181" align="left" class="style3 stylebottom" >&nbsp;<?php echo $phone_no;?></td>
    <td width="221" align="left" class="style3 stylebottom" >&nbsp;<?php echo $email_id;?></td>
    <td align="left" class="style3 stylebottom" >&nbsp;<?php echo ucfirst($address);?></td>
    <td align="left" class="style3 stylebottom" >&nbsp;<?php echo ucfirst($city);?></td>
    
   </tr>
  <?php } ?>
       <td height="30" colspan="16"align="right" class="stylebottom style4 style27" style="border-left:1px solid #999;">Printed Date : <?php echo $curdate=date('d-m-Y');?>&nbsp;&nbsp;&nbsp;&nbsp;<br>Printed Time : <?php echo $current_time=date('h:i:s A');?>&nbsp;&nbsp;<br>IP Address   : <?php echo $ip_address = $_SERVER['REMOTE_ADDR'];?>&nbsp;</p></td>
</table>
