Current File : /home/inlingua/public_html/dwarka/icentex/admin_fd/welcome_note_all.php
<?php
session_start();
//print_r($_SESSION);
ini_set("max_execution_time",0);
require('../dbConnection.php');

// Include common functions
require('../commonFunc.php');

// Include common functions
require('../globalVars.php');
require('../dbHandler.class.php');
$dbObject = new dbHandler();
$dbObject->connect();
//ob_start();
//include("header.php");
?>
<?php
require_once('../tcpdf/config/lang/eng.php');
require_once('../tcpdf/tcpdf.php');

 $query="select * from ingl_student where courseId='$_REQUEST[courseId]'";
 //$query="select * from ingl_student where recNo='2'";
$result=mysqli_query($conn,$query);

// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);

// set document information
$pdf->SetCreator(PDF_CREATOR);
$pdf->SetAuthor('Inlingua');
$pdf->SetTitle('Inlingua');
$pdf->SetSubject('Inlingua');
$pdf->SetKeywords('Inlingua Welcome Note');

// remove default header/footer
$pdf->setPrintHeader(false);
$pdf->setPrintFooter(false);

// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);

//set margins
$pdf->SetMargins('10', '50', '10');

//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);

//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);

//set some language-dependent strings
$pdf->setLanguageArray($l);

// ---------------------------------------------------------

// set font





while($num=mysqli_fetch_array($result))
{
$queryC="select * from  ingl_course where recNo='".$num[courseId]."'";
$resultC=mysqli_query($conn,$queryC);
$numC=mysqli_fetch_array($resultC);

$queryI="select name from timesheet_user where recNo='".$numC[instructor]."'";
$resultI=mysqli_query($conn,$queryI);
$numI=mysqli_fetch_array($resultI);

$pdf->SetFont('times', '', 12);

$fromDate=$num[createDate];


$fromdate1=explode("-",$fromDate);

$fdate1= date("d F Y", mktime(0, 0, 0, $fromdate1[1], $fromdate1[2], $fromdate1[0]));


$content="";
$content.='<table border="0" class="main"  width="100%">';

$content.= '<tr><td colspan="2"><img src="http://inlinguanewdelhi.in/icentex/Capture.png"></td></tr>';

$content.='<tr><td width="75%"></td><td width="25%">Date: '.$fdate1.'</td></tr>';
 $content.= '<tr>     
                      <td colspan="2">
                        <p>Dear <strong>'.$num['studentName'].',</strong></p>
                        <p>Welcome to inlingua. We would like to do everything we can to help you in your aim of learning a language well.</p>
						</td></tr>';
$content.= '<tr><td colspan="2"><p><strong>'.$numC["name_pie"].'</strong>, who is your Personal inlingua Executive, will be happy to offer you any help on administrative matters.<strong> '.$numI["name"].'</strong> will be your instructor for this course.Please also feel free to contact me whenever required. </p></td></tr>';
$content.= '<tr><td colspan="2">To get the most out of your course we recommend that you attend your classes regularly and punctually.</td>
									  </tr>
									  <tr>
									  <td colspan="2">To help you learn the language better, you can take advantage of the <strong>Exclusive Clubs to practice Grammar and Conversation</strong>.</td>
                                    </tr>';
									
$content.= '<tr><td colspan="2">									
<p>Follow us on instagram: https://www.instagram.com/inlinguanewdelhi/?hl=en <br/>
and like our page on facebook: https://www.facebook.com/inlinguadelhiofficial/ </p>
<p>We always look forward to suggestions that will make your time spent at inlinguamore fruitful and memorable. Please share your thoughts with an inlingua executive or Mail us at feedback@inlinguanewdelhi.com

</p>
<p>On behalf of everyone at inlingua, I wish you the very best for your course</p>
<br/>

<p style="text-align:right;">
visit our website: https://www.inlinguanewdelhi.com/ 
</p>
<p>

<strong>Kind Regards </strong> <br/>
Vikram Bajaj <br/>
Center Director<br/>
inlingua New Delhi<br/></p>
                      </td>
                    </tr>
                  
          
            </table>';
           
				
	
//echo $content; exit;

// add a page
$pdf->AddPage();


// set some text to print
$html = <<<EOD
 $content
EOD;
$pdf->writeHTMLCell($w=0, $h=0, $x='', $y='', $html, $border=0, $ln=1, $fill=0, $reseth=true, $align='', $autopadding=true);

}
// print a block of text using Write()
//$pdf->Write($h=0, $txt, $link='', $fill=0, $align='C', $ln=true, $stretch=0, $firstline=false, $firstblock=false, $maxh=0);

// ---------------------------------------------------------

//Close and output PDF document
$pdf->Output('example_002.pdf', 'I');

//============================================================+
// END OF FILE                                                
//============================================================+

?><td style="text-align:justify; font-size:12px;">