<? 
session_start();
if(strlen($brcode)<=0)
{
 print "<script> alert('Session timed out'); parent.document.location='../ind.php'; </script>";
 return;
}

include("../opendb.php");
include("../test.php");
//$result=mysqli_query($db,"select * from veh_trans where invno='$invno' and brcode='$brcode'");
$result=mysqli_query($db,"select * from veh_trans where invno='$invno' and brcode='$brcode'");
$row=mysqli_fetch_array($result);
$re=mysqli_query($db,"select * from branch where brcode='$brcode'");
$brow=mysqli_fetch_array($re);
?>
<style>
td,body{font-family:arial;background-color:white;font-size:12}
</style>
<table width=100%>
<tr><td align=center><span style={letter-spacing:5}><u>  </u></span></TD></TR>


<?
$brname=explode(',',$branch);
//$custadr=$row[addr];
//$custadr=explode('-',$custadr);
?>


</TABLE>
<table width=90%>
<tr><td align=center><p style={letter-spacing:1;font-size:15}><b><?print strtoupper($brow[brname])?></TD></TR>

<TR><TD ALIGN=CENTER><font size=2><?print strtoupper($brow[braddr]).', '.strtoupper($brow[brcity])?></td></tr>
<tr><td align=center><p style={letter-spacing:1;font-size:15}><b>TIN - <?print strtoupper($brow[tin])?></TD></TR>
<TR><TD ALIGN=CENTER><font size=2>Phone : <?print $brow[brphone]?></td></tr>
<tr><td align=center><br><p style={letter-spacing:1;font-size:15}><b><U>VEHICLE TRANSFER CHALLAN</U></TD></TR>
</table>

<br><br>

<center>
<TABLE width=100% border=0>
<tr><td width=400 align=right> </td><td><font size='3'><b>&nbsp;&nbsp;&nbsp;&nbsp; </b></font></td><td ></td><td></td>
</table>
</center>
<TABLE width=100% border=0>
<tr><td></td><td><font size='3'>Challan No.<b> :PSN/VT/00<?print $invno?></b> </td><td></td></tr>
<tr><td></td><td><font size='3'>Challan Date : <b> <?print datetohtml($row[invdate])?></b></td><td></td></tr>
<tr><td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<U><b>FROM </U></td><td> </td><td></td></tr>
<tr><td></td><td> </td><td></td></tr>
<tr><td></td><td> </td><td></td></tr>

<tr><td> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<? print $row[cust]?></td><td></td><td></td></tr>
<tr><td> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<? print $row[custaddr] ?></td><td></td><td></td></tr>
<tr><td> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<? print $custadr[1] ?></td><td></td></tr>
<tr><td> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<? print $custadr[2] ?></td><td></td><td></td></tr>
<tr><td> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<? print $custadr[3] ?></td><td></td><td></td></tr>
</table>
<TABLE width=100% border=0>
<tr><td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<U><b>TO </U></td><td> </td><td></td></tr>
<tr><td></td><td> </td><td></td></tr>
<tr><td></td><td> </td><td></td></tr>
<tr><td> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<? print $row[consignee]?></td><td></td><td></td></tr>
<tr><td> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<? print $row[consaddr]?></td><td></td><td></td></tr>
<tr><td> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<? print $custadr[1] ?></td><td></td></tr>
<tr><td> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<? print $custadr[2] ?></td><td></td><td></td></tr>
<tr><td> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<? print $custadr[3] ?></td><td></td><td></td></tr>
</table>
<TABLE align = center CELLSPACING=1 CELLPADDING=1 BGCOLOR=BLACK width=85% border=1>
<tr align=center><td>SL No.</td><td>Part Code</td><td>Part Name </td><td>Rate</td> <td>Qty.
<td>Unit </td><td>Total</td></tr>

<tr valign=top><td>1</td><td><? ?></td><td><?print $row[config]?></td>
<td align=right><?print $row[unit]?></td><td align=center><?print $row[qty]?></td>
<td align=center>Nos</td>
<td align=right><?print $row[unit]?></td><br><br></td></tr>
</table>
<br><br>
<TABLE CELLSPACING=1 CELLPADDING=1  >
<tr><td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;ENGINE NO:</td><td><?print $row[engno]?></td></tr>

<tr><td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CHASSIS NO:</td><td><?print $row[chasis]?></td></tr>
</table>
<br><br><br>
<TABLE CELLSPACING=1 CELLPADDING=1  >
<tr><td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;REMARKS :</td><td><?print $row[remark]?></td></tr>

</table>
<br><br><br><br><br>
<TABLE width=100% >


</table>
<br><br><br><br><br>
<TABLE width=95% >
<tr><td></td><td>             </td><td>       </td><td>_____________________</td></tr>
<tr><td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td><td> </td><td> </td><td>Authorised Signatory</td></tr>
</table>

 




