<?php 
session_start();
ob_start();
include("../../../pidbco/pidbjoin.php");

$dom = $_GET['dom'];
$sq = mysqli_query($con, "SELECT * FROM `p_domain` WHERE `did`='$dom'");
$rs = mysqli_fetch_array($sq);

$dcust = $rs['dcust'];
$sq2 = mysqli_query($con, "SELECT * FROM `p_customers` WHERE `cid`='$dcust'");
$rs2 = mysqli_fetch_array($sq2);

$dorder = $rs['dorder'];
$sq3 = mysqli_query($con, "SELECT * FROM `p_server` WHERE `s_order`='$dorder' ");
$rs3 = mysqli_fetch_array($sq3);
?>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>Programers</title>
        <style type="text/css">
			table { width:100%; border:none; font-size:11px; }
			.head > div { float:left; border-right:solid 1px #666666; text-align:center; line-height:22px; font-weight:bold; border-bottom:solid 1px #666666; }
			.head > div:last-child { border-right:none; width:13%; }
			.head > div:nth-child(1) { width:5%;}
			.head > div:nth-child(2) { width:54.38%; text-align:left; }
			.head > div:nth-child(3) { width:13%;}
			.head > div:nth-child(4) { width:13%; }
			
			.head1 > div { float:left; border-right:solid 1px #666666; text-align:center; line-height:20px; font-weight:bold; border-bottom:solid 1px #666666; }
			.head1 > div:last-child { border-right:none; width:13%;}
			.head1 > div:nth-child(1) { width:23%;}
			.head1 > div:nth-child(2) { width:25.20%;  }
			.head1 > div:nth-child(3) { width:23%;}
			.head1 > div:nth-child(4) { width:28%;}
			
			.head-body1 > div { float:left; border-right:solid 1px #666666; text-align:center; line-height:20px; border-bottom:solid 1px #666666;   }
			.head-body1 > div:last-child { border-right:none; width:13%; text-align:right;}
			.head-body1 > div:nth-child(1) { width:23%;}
			.head-body1 > div:nth-child(2) { width:25.20%;}
			.head-body1 > div:nth-child(3) { width:23%;border-bottom:none;}
			.head-body1 > div:nth-child(4) { width:28%;}
			
			
			.head-body > div { float:left; border-right:solid 1px #666666; text-align:center; line-height:30px;  height:300px;  }
			.head-body > div:last-child { border-right:none; width:13%; text-align:right;}
			.head-body > div:nth-child(1) { width:5%;}
			.head-body > div:nth-child(2) { width:64.38%; text-align:left;}
			.head-body > div:nth-child(3) { width:5%;}
			.head-body > div:nth-child(4) { width:12%; text-align:right;}
			
			.head-body-content { overflow:hidden; line-height:20px;}
			.head-body-content > div { float:left; text-align:center; line-height:30px; margin:10px 0px;}
			.head-body-content > div:last-child {  width:13.62%; text-align:right;}
			.head-body-content > div:nth-child(1) { width:5%;}
			.head-body-content > div:nth-child(2) { width:63.38%; text-align:left; text-transform:uppercase; line-height:15px; font-size:10px;}
			.head-body-content > div:nth-child(3) { width:5%;}
			.head-body-content > div:nth-child(4) { width:12%; text-align:right;}
			
			.head-body-total {border:solid 1px #666666; overflow:hidden; border-top:none;}
			.head-body-total > div { float:left; text-align:right; line-height:20px; }
			.head-body-total > div:last-child {  width:12.86%; float:right; }
			.head-body-total > div:nth-child(1) { width:84.5%;padding-right:10px; font-size:10px; border-right:solid 1px #666666;}
			
			.head-body-total1 {border:solid 1px #666666; overflow:hidden; border-top:none;}
			.head-body-total1 > div { float:left; text-align:right; line-height:20px; }
			.head-body-total1 > div:last-child {  width:12.86%; float:right; }
			.head-body-total1 > div:nth-child(1) { width:86%; font-size:10px; border-right:solid 1px #666666; }
			
		</style>
        
    </head>

	<body style="font-family:Arial, Helvetica, sans-serif; font-size:11px; margin:0px;" onLoad="print();">
	
        <div style="width:100%; height:100%; overflow:hidden; top:0px; bottom:0px; left:0px; right:0px; margin:auto;">
            
           
            
            <div style="width:100%; float:left; min-height:250px; overflow:hidden;">
            	
                <div style="padding-left:25px;">
                	
                    <table>
                    <tr>
                    
                        <td style="width:50%;">
                            <img src="images/logo.jpg" style="" />
                        </td>
                        
                        <td style="width:50%;">
                            <div style="line-height:13px; color:#000; text-align:right;  font-size:12px;">
                            <b><u>Our Associates</u></b><br>
                            <span style=" font-size: 11px;">Programers Resources</span><br>
                            <span style=" font-size: 11px;">Programers International</span><br>
                           <span style=" font-size: 11px;"> Programers Web Technologies</span><br>
                           <span style=" font-size: 11px;"> Programers Software Solution</span>
                            </div>
                        </td>
                    
                    </tr>
                    </table>
            
                    
                    <div style="width:100%; margin-bottom:2px; border-top:solid 1px #666666; padding-top:2px;">
                    	<div align="center" style=" font-size: 14px;"><b>Domain Renewal Intimation</b></div>
                    </div>
                          
                            <table>
                    <tr>
                        <td style="width:80%;">
                           To : The Managing Director<br>
                          &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;    <?php echo $rs2['cname']; ?><br>
                          <?php if(($rs2['cdistrict'] != '') && ($rs2['cstate'] != '') && ($rs2['ccountry'] != '')){ ?>
                          &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;    <?php echo $rs2['cdistrict'].','.$rs2['cstate'].','.$rs2['ccountry']; ?><br>
                          <?php } ?>
                          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;    Ph : <?php echo $rs2['cmob']; ?>
                        </td>
                        <td style="width:20%;">
                            <div style="line-height:18px; color:#000; text-align:right;  font-size:12px;">
                            <span style=" font-size: 12px;">
                            <?php 
                            $originalDate = date('Y-m-d');
                            $newDate = date("d M Y", strtotime($originalDate));
                            echo $newDate;
                            ?></span><br>
                            </div>
                        </td>
                    
                    </tr>
                    </table>
                    <br>
                    <span >Dear Sir/Madam,</span>
                    <br><br>
                    <span> Reg: Renewal intemation of your Website &nbsp;&nbsp;&nbsp;&nbsp; <?php echo $rs['d_domain']; ?> &nbsp;&nbsp;&nbsp;&nbsp; Expiry : 
                    	<?php $originalDate2 = $rs['d_renewel'];
                              $newDate2 = date("d M Y", strtotime($originalDate2));
                              echo $newDate2; ?></span>
                    
                    
                    <div style="width:100%;  border-top:solid 1px #666666; padding-top:5px;">
                    	<span>Thank you for choosing PROGRAMERS.It is our constant endeavor to see to it that we provide prompt and quality service for your Esteemed Organization 
                    		Further if you have any complaints or suggestions, dont hesitate to contact us. For domain availability and registration please
                    		visit www.programersglobal.com or Call 9447443598/9447151442</span>
                    	<br><br>
                    	<span>Financial Quote</span>	
                    </div>	
                                 
                    <div style="width:99.7%; border:solid 1px #666666; overflow:hidden; height:205px;">
                    	
                      
                       
                       <div class="head">
                        	
                            <div>1</div>
                            <div >&nbsp; Domain Name Registration</div>
                            <div>1</div>
                            <div style="text-align: right;" ><?php if($rs['d_amnt'] != ''){ echo number_format($rs['d_amnt'],2); } else { echo '0.00'; }?></div>
                            <div style="text-align: right;"><?php if($rs['d_amnt'] != ''){ echo number_format($rs['d_amnt'],2); } else { echo '0.00'; }?></div>
                            
                       </div>
                       
                       <div class="head">
                            <div>2</div>
                            <div>&nbsp; Dedicated/VPS Server</div>
                            <div><?php if($rs3['s_space'] != ''){ echo $rs3['s_space']; } else { echo '0.00'; } ?></div>
                            <div style="text-align: right;" ><?php if($rs3['s_amnt'] != ''){ echo number_format($rs3['s_amnt'],2); } else { echo '0.00'; } ?></div>
                             <div style="text-align: right;"><?php if($rs3['s_amnt'] != ''){ echo number_format($rs3['s_amnt'],2); } else { echo '0.00'; } ?></div>
                       </div>
                       
                       <div class="head">
                            <div>3</div>
                            <div>&nbsp; POP3 Email Account (Each 250 MB)</div>
                            <div>0</div>
                            <div style="text-align: right;">0.00</div>
                            <div style="text-align: right;">0.00</div>
                       </div>
                       
                       <div class="head">
                            <div>4</div>
                            <div> &nbsp; Hosting Charge(setup Charge)</div>
                            <div>&nbsp;</div>
                            <div style="text-align: right;">0.00</div>
                            <div style="text-align: right;">0.00</div>
                       </div>
                       
                       <div class="head">
                            <div>5</div>
                            <div> &nbsp;DSN-Database MS/MY SQL</div>
                            <div>0</div>
                            <div style="text-align: right;">0.00</div>
                            <div style="text-align: right;">0.00</div>
                       </div>
                       
                       
                       <div class="head">
                            <div>6</div>
                            <div>&nbsp; Programming-Charge</div>
                            <div>&nbsp; </div>
                            <div style="text-align: right;">0.00</div>
                            <div style="text-align: right;">0.00</div>
                       </div>
                       
                       <div class="head">
                            <div>7</div>
                            <div>&nbsp; Domain Re-Directory Change</div>
                            <div>&nbsp;</div>
                            <div style="text-align: right;">0.00</div>
                            <div style="text-align: right;">0.00</div>
                       </div>
                       
                       <div class="head">
                            <div>8</div>
                            <div>&nbsp; Website Technical Support Charges</div>
                            <div>0</div>
                            <div style="text-align: right;">0.00</div>
                            <div style="text-align: right;">0.00</div>
                       </div>
                       
                       <div class="head" style="border-bottom:none;">
                            <div>9</div>
                            <div>&nbsp; Others	</div>
                            <div>&nbsp;</div>
                            <div style="text-align: right;">0.00</div>
                            <div style="text-align: right;">0.00</div>
                       </div>
                       
                        
                        <div style="clear:both;"></div>
                       
                        
                    </div>
                        
                    <div class="head-body-total" style="border-top:none;"> 
                        	
                        <div>
                        	<b>Grand Total</b>
                        </div>
                        <div>
                        	<b><?php
                        	   $granttot = $rs['d_amnt']+$rs3['s_amnt'];                      	   
                        	   echo number_format($granttot,2); ?></b> &nbsp;
                        </div>
                        
                    </div>
                    <div style="clear:both;"></div>
                   
                  
                    
                    
                    <div style="clear:both;"></div>
                      <b style=" float: right; margin-right:35px;">Support &nbsp; :  &nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
                      	<?php $servicetx = (($granttot*14)/100);
                            echo number_format($servicetx,2); ?></b><br>
                      <b style=" float: right;margin-right:30px;">Net Total &nbsp; :  &nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                      	<?php 
                      	$netvalue = $granttot+$servicetx;
                      	echo number_format($netvalue,2); ?></b>
                      
                    
                      
                       <span>Validity : This intimation is valid only for 10 days before the expiry of domain</span><br>
                       <p>Payment  : Payment should be made before 30 days from the date of Domain/Server expiry. If the party fails to do so then PROGRAMERS international will not 
                      	be responsible for the loss of domain or other technician difficulties .The payment should be made through Cash/DD/Cheque(for outstation or
                      	non-MICR cheque and RS.100 in addition) payable to "PROGRAMERS INTERNATIONAL",Thrissur </p>
                     
                      	<p>Hope you will find our service excellent and we look forward for a long-term business relation with our company. 
                      		Once again we thank you for your interest in PROGRAMERS</p>
                      
                      
                       
                    
                    <table style="margin-top:6px;">
                    <tr>
                    	
                      
                        
                        <td style="text-align:left;">
                        	Sincerely, <br>
                        	For PROGRAMERS International<br />
                            <img src="images/signature.jpg" alt="" style="width:75px;" /><br /> 
                            Web Master
                        </td>
                          <td>
                          	<div style=" border: 1px dotted #000000; float: right; width: 300px; ">
                        	<b>&nbsp;Out Bank Details</b><br>
                        	&nbsp;&nbsp;A/c Name  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : &nbsp; Programers International<br>
                        	&nbsp;&nbsp;Bank Name  &nbsp;&nbsp;&nbsp; : &nbsp; Bank of Baroda<br>
                        	&nbsp;&nbsp;A/c No.    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : &nbsp; 08350200000182<br>
                        	&nbsp;&nbsp;IFSC     &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  : &nbsp; BARB O TRICHU<br>
                        	&nbsp;&nbsp;Branch  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  : &nbsp; Thrissur<br>
                        	</div>
                        </td>
                        
                        
                    </tr>
                    </table>
                    <style>
                    li {
                    	float: left;
                    	
                    }
                    ul {
                    	width: 90%;
                       
                    }
                    </style>
                     <div  >
                     	<ul type="square">
                    	<li>Software Solution</li>
                    	<li style="margin-left:20px;">Web Hosting & Designs</li>
                    	<li style="margin-left:20px;">SEO & Internet Advertsing</li>
                    	<li style="margin-left:20px;">Logo & Graphics Designs</li>
                    	<li>Security Surveillance</li>
                    	<li style="margin-left:20px;">Animation(2D & 3D)</li>
                    	<li style="margin-left:20px;">Net Working (LAN & WAN)</li>
                    	<li style="margin-left:20px;">Visual Media Advertising</li>
                    </ul>
                    </div>
                     <div style="clear:both;"></div>
                  
                   <div style="width:100%; margin-bottom:5px; border-top:solid 1px #666666; padding-top:5px;">
                    	4th Floor, Park House, Round North, Thrissur -680001, Kerala - India. Mob: +91 9447151442 / 9447443598 / 9445951442<br />
                        Email : info@programers.in,url: www.programers.in
                    </div>
                    
                </div>
                
            </div>
            
        </div>
	
   
	</body>
    
</html>
