<?php
	include "db_connection/db_connection.php";
	include "config/config.php";
	
	if($_SESSION['admin_login_id'] == '')
	{
		echo "<script>window.location='index.php';</script>";
	}
	if(isset($_GET['em_id']) && isset($_GET['fin_dt']))
	{
		$em_id   = $_GET['em_id'];
		$fin_dt  = $_GET['fin_dt'];
		$flagg   = 1;
	}
	else
	{
		$flagg   = 2;
	}
?> 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="https://www.w3.org/1999/xhtml">
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" />
        <title><?php echo $PROJECT_TITLE ?></title>
        
        
        <link href="css/styles.css" rel="stylesheet" type="text/css" />
        <!--[if IE]> <link href="css/ie.css" rel="stylesheet" type="text/css"> <![endif]-->
        
        <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7/jquery.min.js"></script>
        <script type="text/javascript" src="js/waiting_for_appr_JS.js"></script>
        <script type="text/javascript" src="js/plugins/forms/ui.spinner.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.mousewheel.js"></script>
         
        <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
        
        <script type="text/javascript" src="js/plugins/charts/excanvas.min.js"></script>
        <script type="text/javascript" src="js/plugins/charts/jquery.flot.js"></script>
        <script type="text/javascript" src="js/plugins/charts/jquery.flot.orderBars.js"></script>
        <script type="text/javascript" src="js/plugins/charts/jquery.flot.pie.js"></script>
        <script type="text/javascript" src="js/plugins/charts/jquery.flot.resize.js"></script>
        <script type="text/javascript" src="js/plugins/charts/jquery.sparkline.min.js"></script>
        
        <script type="text/javascript" src="js/plugins/tables/jquery.dataTables.js"></script>
        <script type="text/javascript" src="js/plugins/tables/jquery.sortable.js"></script>
        <script type="text/javascript" src="js/plugins/tables/jquery.resizable.js"></script>
        
        <script type="text/javascript" src="js/plugins/forms/autogrowtextarea.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.uniform.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.inputlimiter.min.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.tagsinput.min.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.maskedinput.min.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.autotab.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.chosen.min.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.dualListBox.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.cleditor.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.ibutton.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.validationEngine-en.js"></script>
        <script type="text/javascript" src="js/plugins/forms/jquery.validationEngine.js"></script>
        
        <script type="text/javascript" src="js/plugins/uploader/plupload.js"></script>
        <script type="text/javascript" src="js/plugins/uploader/plupload.html4.js"></script>
        <script type="text/javascript" src="js/plugins/uploader/plupload.html5.js"></script>
        <script type="text/javascript" src="js/plugins/uploader/jquery.plupload.queue.js"></script>
        
        <script type="text/javascript" src="js/plugins/wizards/jquery.form.wizard.js"></script>
        <script type="text/javascript" src="js/plugins/wizards/jquery.validate.js"></script>
        <script type="text/javascript" src="js/plugins/wizards/jquery.form.js"></script>
        
        <script type="text/javascript" src="js/plugins/ui/jquery.collapsible.min.js"></script>
        <script type="text/javascript" src="js/plugins/ui/jquery.breadcrumbs.js"></script>
        <script type="text/javascript" src="js/plugins/ui/jquery.tipsy.js"></script>
        <script type="text/javascript" src="js/plugins/ui/jquery.progress.js"></script>
        <script type="text/javascript" src="js/plugins/ui/jquery.timeentry.min.js"></script>
        <script type="text/javascript" src="js/plugins/ui/jquery.colorpicker.js"></script>
        <script type="text/javascript" src="js/plugins/ui/jquery.jgrowl.js"></script>
        <script type="text/javascript" src="js/plugins/ui/jquery.fancybox.js"></script>
        <script type="text/javascript" src="js/plugins/ui/jquery.fileTree.js"></script>
        <script type="text/javascript" src="js/plugins/ui/jquery.sourcerer.js"></script>
        
        <script type="text/javascript" src="js/plugins/others/jquery.fullcalendar.js"></script>
        <script type="text/javascript" src="js/plugins/others/jquery.elfinder.js"></script>
        
        <script type="text/javascript" src="js/plugins/ui/jquery.easytabs.min.js"></script>
        <script type="text/javascript" src="js/files/bootstrap.js"></script>
        <script type="text/javascript" src="js/files/functions.js"></script>
        
        <!-- Shared on MafiaShare.net  --><!-- Shared on MafiaShare.net  --></head>
        
        <body onload="document.getElementById('listpage').focus();">
        
        <!-- Top line begins -->
        <?php include "header_footer/header.php"; ?>
        <!-- Top line ends -->
        
        
        <!-- Sidebar begins -->
        <?php include "menus/left_menu.php"; ?>
        <!-- Sidebar ends -->
        
        
        
        <!-- Content begins -->
        <div id="content">
            <!--<div class="contentTop">
                <span class="pageTitle"><span class="icon-key-2"></span>Form validation engines</span>
                <ul class="quickStats">
                    <li>
                        <a href="" class="blueImg"><img src="images/icons/quickstats/plus.png" alt="" /></a>
                        <div class="floatR"><strong class="blue">5489</strong><span>visits</span></div>
                    </li>
                    <li>
                        <a href="" class="redImg"><img src="images/icons/quickstats/user.png" alt="" /></a>
                        <div class="floatR"><strong class="blue">4658</strong><span>users</span></div>
                    </li>
                    <li>
                        <a href="" class="greenImg"><img src="images/icons/quickstats/money.png" alt="" /></a>
                        <div class="floatR"><strong class="blue">1289</strong><span>orders</span></div>
                    </li>
                </ul>
                <div class="clear"></div>
            </div>-->
            <?php include "menus/top_menu.php"; ?> 
            <!-- Breadcrumbs line -->
            <div class="breadLine">
                <div class="bc">
                    <ul id="breadcrumbs" class="breadcrumbs">
                        <li><a href="home.php">Dashboard</a></li>
                        <li><a href="javascritp:">CAD Finish</a></li>
                        
                    </ul>
                </div>        
                <?php include "menus/top_left_menu.php"; ?>  
            </div>          
            <!-- Main content -->
            <div class="wrapper">
            	<?php
				if($flagg==1)
				{
				?>
                    <ul class="middleNavR">
                        <li><a href="cad_finish_add.php?em_id=<?php echo $em_id; ?>&fin_dt=<?php echo $fin_dt; ?>" id="listpage" title="List Cad Design" class="tipN"><img src="images/icons/middlenav/stats.png" alt="" /></a></li>
                    </ul>
                <?php
				}
					$page_id = base64_encode(base64_encode(base64_encode(base64_encode(1))));
					$des_no  = base64_decode(base64_decode(base64_decode(base64_decode($_GET['des_id']))));
					$emp_ad_id  = base64_decode(base64_decode(base64_decode(base64_decode($_GET['emp_ad_id']))));
					$emp_cur_id  = base64_decode(base64_decode(base64_decode(base64_decode($_GET['emp_cur_id']))));
					
					$SLCT_CAD = "SELECT * FROM emp_current_design,design_det WHERE design_det.design_det_id = emp_current_design.design_det_id AND emp_current_design.design_det_id = '$des_no' AND emp_current_design.emp_det_id='$emp_ad_id' AND emp_current_design.emp_current_design_id='$emp_cur_id'";
					//echo $SLCT_CAD;
					$QURY_CAD = mysqli_query($connect,$SLCT_CAD);
					$FTCH_CAD = mysqli_fetch_object($QURY_CAD);
					
					$cur_ad_id  = base64_encode(base64_encode(base64_encode(base64_encode($FTCH_CAD->emp_current_design_id))));
					
					$SLCT_CURR_TIM = "SELECT SEC_TO_TIME( SUM( TIME_TO_SEC( `time_taken` ) ) ) AS tot_time FROM emp_current_design_det WHERE emp_current_design_id = '$FTCH_CAD->emp_current_design_id'";
					$QURY_CURR_TIM = mysqli_query($connect,$SLCT_CURR_TIM);
					$FTCH_CURR_TIM = mysqli_fetch_object($QURY_CURR_TIM);
					
					$SLCT_t = "SELECT * FROM master_cad_cat WHERE master_cad_cat_id = '$FTCH_CAD->master_cad_cat_id'";
					$QURY_t = mysqli_query($connect,$SLCT_t);
					if(mysqli_num_rows($QURY_t )>0)
					{
						$FTCH_t = mysqli_fetch_object($QURY_t);
						$cad_cat_name = $FTCH_t->cad_cat_name;
						$cad_pnts = $FTCH_t->cad_points;
					}
					else
					{ 
						$cad_cat_name = "------"; 
						$cad_pnts="----"; 
					}
					
					$SLCT_re = "SELECT * FROM emp_current_design_rework WHERE emp_det_id = '$emp_ad_id' AND design_det_id='$des_no'";
					$QURY_re = mysqli_query($connect,$SLCT_re);
					if(mysqli_num_rows($QURY_re)>0)
					{
						$FTCH_t = mysqli_fetch_object($QURY_re);
						$re_pnts = $FTCH_t->rework_pnts;
					}
					else
					{
						$re_pnts = $cad_pnts;
					}
					
					$SLCT_d = "SELECT * FROM master_cat WHERE master_cat_id = '$FTCH_CAD->master_cat_id'";
					//echo $SLCT_d;
					$QURY_d = mysqli_query($connect,$SLCT_d);
					$FTCH_d = mysqli_fetch_object($QURY_d);	
					
					$SLCT_em = "SELECT * FROM emp_det WHERE emp_det_id = '$emp_ad_id'";
					//echo $SLCT_d;
					$QURY_em = mysqli_query($connect,$SLCT_em);
					$FTCH_em = mysqli_fetch_object($QURY_em);		
					
					if($FTCH_CAD->curr_status=='finished' || $FTCH_CAD->curr_status=='waiting')
					{
						$imag_1 = "../cad_fin_images/M.".$FTCH_CAD->img_ext; 
						$imag_2 = "../cad_fin_images/L.".$FTCH_CAD->img_ext;
						$img_flagg = 1;
					}
					else
					{
						$img_flagg = 2;
						$imag_detM = "../design_images/M.".$FTCH_CAD->imag_ext; 
						$imag_detL = "../design_images/L.".$FTCH_CAD->imag_ext;
					}						
					if($FTCH_CAD->mas_fin_ext!=''){ $imag = "../mas_fin_images/M.".$FTCH_CAD->mas_fin_ext; $imag1 = "../mas_fin_images/L.".$FTCH_CAD->mas_fin_ext; }
						
					else if($FTCH_CAD->cad_fin_ext!=''){ $imag = "../cad_fin_images/M.".$FTCH_CAD->cad_fin_ext; $imag1 = "../cad_fin_images/L.".$FTCH_CAD->cad_fin_ext; }
					
					else if($FTCH_CAD->imag_ext!=''){ $imag = "../design_images/M.".$FTCH_CAD->imag_ext; $imag1 = "../design_images/L.".$FTCH_CAD->imag_ext; }
					
              	?>
                <form id="validate" name="cur_des" class="main" method="post" action="" enctype="multipart/form-data">
                	<fieldset>
                    	<input type="hidden" name="des_no" id="des_no" value="<?php echo $_GET['des_no']; ?>" />
                        <input type="hidden" name="emp_id" id="emp_id" value="<?php echo $_GET['emp_ad_id']; ?>" />
                        <input type="hidden" name="cad_pnts" id="cad_pnts" value="<?php echo $cad_pnts; ?>" />
                		<div class="fluid">
                			<div class="widget">
                				<div class="formRow">
                					<table width="100%">
                                    	<tr>
                                        	<td width="10%" style="display:table-cell; vertical-align:middle;"><strong>Designer Name  :  </strong></td>
                                            <td width="14%" style="display:table-cell; vertical-align:middle;"><?php echo $FTCH_em->name; ?></td>
                                            <td width="10%" style="display:table-cell; vertical-align:middle;"><strong>Design No  :  </strong></td>
                                            <td width="10%" style="display:table-cell; vertical-align:middle;"><?php echo $FTCH_d->master_cat_name." ".$FTCH_CAD->design_no; ?></td>
                                            <td width="6%" style="display:table-cell; vertical-align:middle;"><strong>Point  :  </strong></td>
                                            <td width="6%" style="display:table-cell; vertical-align:middle;"><?php echo $re_pnts; ?></td>
                                            <td width="14%" style="display:table-cell; vertical-align:middle;"><strong>Approximate Weight  :  </strong></td>
                                            <td width="6%" style="display:table-cell; vertical-align:middle;"><?php echo $FTCH_CAD->approximate_weight." g"; ?></td>
                                            <td width="10%" style="display:table-cell; vertical-align:middle;"><strong>Total Time  :  </strong></td>
                                            <td width="10%" style="display:table-cell; vertical-align:middle;"><?php echo $FTCH_CURR_TIM->tot_time; ?> hrs</td>
                                        </tr>
                                    </table>
                				</div>
                                <div class="formRow">
                                	<table width="100%">
                                    	<tr>
                                        	<td width="80%" style="vertical-align:top; text-align:center; display:table-cell;">
                                            	<div class="widget" style="margin-top:0px;">
                                                    <table cellpadding="0" cellspacing="0" width="100%" class="tDefault" id="resize2">
                                                        <thead>
                                                            <tr>
                                                                <td class="sortCol" width="8%"><div>S.no<span></span></div></td>
                                                                <td class="sortCol" width="15%"><div>W.app Date<span></span></div></td>
                                                                <td class="sortCol" width="15%"><div>App. Date<span></span></div></td>
                                                                <td class="sortCol" width="10%"><div>Admin<span></span></div></td>
                                                                <td class="sortCol" width="15%"><div>Cad Volume<span></span></div></td>
                                                                <td class="sortCol" width="15%"><div>Des. Height<span></span></div></td>
                                                                <td class="sortCol" width="15%"><div>Des. Width<span></span></div></td>
                                                                <td class="sortCol" width="20%"><div>Remarks<span></span></div></td>
                                                            </tr>
                                                        </thead>
                                                        <tbody>
                                                        	<?php
																$i=1;
																$SLCT_CURR_APP  = "SELECT * FROM emp_current_design_det WHERE emp_current_design_id='$FTCH_CAD->emp_current_design_id' AND (waiting_app_dt!='' OR approved_dt!='')";
																//echo $SLCT_CURR_DET;
																$EXEC_CURR_APP 	= mysqli_query($connect,$SLCT_CURR_APP);
																while($FTCH_CURR_APP	= mysqli_fetch_object($EXEC_CURR_APP))
																{
															?>
                                                                    <tr>
                                                                        <td class="sortCol"><div><?php echo $i; ?><span></span></div></td>
                                                                        <td class="sortCol"><div><?php echo $FTCH_CURR_APP->waiting_app_dt; ?><span></span></div></td>
                                                                        <td class="sortCol"><div><?php echo $FTCH_CURR_APP->approved_dt; ?><span></span></div></td>
                                                                        <td class="sortCol"><div><?php echo $FTCH_CURR_APP->appr_name; ?><span></span></div></td>
                                                                        <td class="sortCol"><div><?php echo $FTCH_CURR_APP->cad_vol; ?><span></span></div></td>
                                                                        <td class="sortCol"><div><?php echo $FTCH_CURR_APP->design_height; ?><span></span></div></td>
                                                                        <td class="sortCol"><div><?php echo $FTCH_CURR_APP->design_width; ?><span></span></div></td>
                                                                        <td class="sortCol"><div><?php echo $FTCH_CURR_APP->remarks; ?><span></span></div></td>
                                                                    </tr>
                                                          	<?php
																	$i++;
																}
																if($FTCH_CAD->curr_status=='stopped' || $FTCH_CAD->curr_status=='closed')
																{
															?>
                                                            		<tr>
                                                                        <td class="sortCol" colspan="8" align="center"><strong><div>Closed Date : <?php echo $FTCH_CAD->closed_dt; ?><span></span></div></strong></td>
                                                                    </tr>
                                                            <?php
																}
															?>
                                                        </tbody>
                                                    </table>
                                                </div>                                                
                                            </td>
                                            <td width="20%" style="vertical-align:top; text-align:center; display:table-cell;">                                            	
												<?php 
                                                    if($img_flagg==1)
                                                    {
                                                ?>
                                                		<div class="body" style="height:200;text-align:center">
                                                            <a href="<?php echo $imag1; ?>" title="<?php echo $FTCH_d->master_cat_name." ".$FTCH_CAD->design_no; ?>" class="lightbox" rel="group"><img src="<?php echo $imag; ?>" width="220" height="220"/></a>
                                                        </div><br />
                                                        <div class="body" style="height:200;text-align:center">
                                                            <a href="<?php echo $imag_2; ?>" title="<?php echo $FTCH_d->master_cat_name." ".$FTCH_CAD->design_no; ?>" class="lightbox" rel="group"><img src="<?php echo $imag_1; ?>" width="220" height="220"/></a>
                                                        </div>
                                                <?php
                                                    }
													else if($img_flagg==2)
                                                    {
                                                ?>
                                                		<div class="body" style="height:200;text-align:center">
                                                            <a href="<?php echo $imag_detL; ?>" title="<?php echo $FTCH_d->master_cat_name." ".$FTCH_CAD->design_no; ?>" class="lightbox" rel="group"><img src="<?php echo $imag_detM; ?>" width="220" height="220"/></a>
                                                        </div>
                                                		<div class="body" style="height:200;text-align:center">
                                                            <a href="<?php echo $imag1; ?>" title="<?php echo $FTCH_d->master_cat_name." ".$FTCH_CAD->design_no; ?>" class="lightbox" rel="group"><img src="<?php echo $imag; ?>" width="220" height="220"/></a>
                                                        </div>
                                                <?php
                                                    }
                                                ?>
                                            </td>
                                       	</tr>
                                    </table>
                				</div>
                			</div>
                      	</div>
                        <div class="widget">
                            <!--<div style="max-height:700px; overflow-y:auto;">-->
                                <table cellpadding="0" cellspacing="0" width="100%" class="tDefault" id="resize2">
                                    <thead>
                                        <tr>
                                            <td class="sortCol" width="10%"><div>S.no<span></span></div></td>
                                            <td class="sortCol" width="15%"><div>Date<span></span></div></td>
                                            <td class="sortCol" width="15%"><div>Start Time<span></span></div></td>
                                            <td class="sortCol" width="20%"><div>End Time<span></span></div></td>
                                            <td class="sortCol" width="20%"><div>Time Taken<span></span></div></td>
                                            <td class="sortCol" width="20%"><div>Total Design Time<span></span></div></td>
                                        </tr>
                                    </thead>
                                    <tbody>
                                    	<?php
											$loop=1;
											$SLCT_CURR = "SELECT * FROM emp_current_design_det WHERE emp_current_design_id = '$FTCH_CAD->emp_current_design_id'";
											$QURY_CURR = mysqli_query($connect,$SLCT_CURR);
											while($FTCH_CURR = mysqli_fetch_object($QURY_CURR))
											{
												if($loop%2 != "0")
													$bg = "gradeX";
												else
													$bg = "class='gradeC'";
										?>
                                                <tr>
                                                    <td style="display:table-cell; vertical-align:middle;" align="center"><?php echo $loop; ?></td>
                                                    <td style="display:table-cell; vertical-align:middle;" align="center"><?php echo str_replace("-","/",$FTCH_CURR->work_dt); ?></td>
                                                    <td style="display:table-cell; vertical-align:middle;" align="center"><?php echo $FTCH_CURR->start_time; ?></td>
                                                    <td style="display:table-cell; vertical-align:middle;" align="center"><span id="out_div<?php echo $loop; ?>"><?php echo $FTCH_CURR->end_time; ?></span></td>
                                                    <td style="display:table-cell; vertical-align:middle;" align="center"><span id="tak_div<?php echo $loop; ?>"><?php echo $FTCH_CURR->time_taken; ?></span></td>
                                                    <td style="display:table-cell; vertical-align:middle;" align="center"><span id="tot_div<?php echo $loop; ?>"><?php echo $FTCH_CURR->tot_time; ?></span></td>
                                                </tr>
                                        <?php
												$loop++;
											}
										?>
                                    </tbody>
                                </table> 
                                <input type="hidden" name="tot_loop" id="tot_loop" value="<?php echo $loop; ?>" />
                            <!--</div>-->
                        </div>
						<?php
							$loop2=1;
							$SLCT_STN = "SELECT * FROM emp_current_design_stone WHERE design_det_id = '$des_no' AND emp_det_id='$emp_ad_id' AND statu_s='1'";
							$QURY_STN = mysqli_query($connect,$SLCT_STN);
							if(mysqli_num_rows($QURY_STN)>0)
							{
						?>
								<div class="widget" >
									<table width="100%" class="tDefault" id="resize2">
										<thead>
											<tr>
												<td align="center"  width="5%" style="display:table-cell; vertical-align:middle;"><strong>Sl No</strong></td>
												<td align="center" width="20%" style="display:table-cell; vertical-align:middle;"><strong>Stone Shape</strong></td>
												<td align="center" width="20%" style="display:table-cell; vertical-align:middle;"><strong>Stone Size</strong></td>
												<td align="center" width="15%" style="display:table-cell; vertical-align:middle;"><strong>Stone Weight</strong></td>
												<td align="center" width="15%" style="display:table-cell; vertical-align:middle;"><strong>Quantity</strong></td>
												<td align="center" width="15%" style="display:table-cell; vertical-align:middle;"><strong>Total Weight</strong></td>
											</tr>
										</thead>
                                    	<tbody>
										<?php
											while($FTCH_STN = mysqli_fetch_object($QURY_STN))
											{
												$SLCT_STN1 = "SELECT * FROM mas_stone_cat WHERE mas_stone_cat_id = '$FTCH_STN->mas_stone_cat_id'";
												$QURY_STN1 = mysqli_query($connect,$SLCT_STN1);
												$FTCH_STN1 = mysqli_fetch_object($QURY_STN1);	
												
												$SLCT_STN2 = "SELECT * FROM mas_stone_type WHERE mas_stone_type_id = '$FTCH_STN->mas_stone_type_id'";
												$QURY_STN2 = mysqli_query($connect,$SLCT_STN2);
												$FTCH_STN2 = mysqli_fetch_object($QURY_STN2);
										?>
												<tr>
													<td align="center" width="5%" style="display:table-cell; vertical-align:middle;"><?php echo $loop2; ?></td>
													<td align="center" width="20%" style="display:table-cell; vertical-align:middle;"><?php echo $FTCH_STN1->cat_name; ?></td>
													<td align="center" width="20%" style="display:table-cell; vertical-align:middle;"><?php echo $FTCH_STN2->stone_name; ?></td>
													<td align="center" width="15%" style="display:table-cell; vertical-align:middle;"><?php echo number_format($FTCH_STN->stone_weight,4)." g"; ?></td>
													<td align="center" width="15%" style="display:table-cell; vertical-align:middle;"><?php echo $FTCH_STN->quantity; ?></td>
													<td align="center" width="15%" style="display:table-cell; vertical-align:middle;"><?php echo number_format($FTCH_STN->total_weight,4)." g"; ?></td>
												</tr>
										<?php
												$loop2++;
											}
										?>
												<tr>
													<td align="center" colspan="4" style="display:table-cell; vertical-align:middle;">&nbsp;</td>
													<td align="center" width="15%" style="display:table-cell; vertical-align:middle;"><strong>Total Stone Weight</strong></td>
													<td align="center" width="15%" style="display:table-cell; vertical-align:middle;"><?php echo number_format($FTCH_CAD->total_stone_weight,4)." g"; ?></td>
												</tr>
										</tbody>
									</table>
									<div class="clear"></div>
								</div>
						<?php
							}
						?>
                	</fieldset>
                </form>              
            </div>
            <!-- Main content ends -->
        </div>       
        <!-- Content ends -->
    </body>
</html>
