Current File : /home/inlingua/www/icentex/admin_fd/ingl_payment_gateway.form.php
<?php
//  Created on: 16-05-2013

// Include header
include "header_fd.php";
?>

<h3 class='pa-nor-navbar'>Add New Online Payment</h3>

<?php
echo $succFailMesg; 

// Show result of a form submission?
if ($showResult == "Y")
{	echo "<br><a href='ingl_payment_gateway.select.php'>Back</a><br>";
	// Include footer
	include "footer_fd.php";
	return; 
}

?>

<script type="text/javascript" src="js/jquery.validate.min.js"></script>

<script type="text/javascript" src="js/student.js"></script>

<script language="javascript">
<!--
function validate1() 
{	if (document.aForm.recNo.value=="")
	{	alert("recNo cannot be blank. Please enter it.");
		document.aForm.recNo.focus(); return false;
	}
	
	if (document.aForm.Name.value=="")
	{	alert("Name cannot be blank. Please enter it.");
		document.aForm.Name.focus(); return false;
	}
	
	if (document.aForm.amount_to_pay.value=="" || document.aForm.amount_to_pay.value=="0.00" )
	{	alert("Amount cannot be blank. Please enter it.");
		document.aForm.amount_to_pay.focus(); return false;
	}
	
	if (document.aForm.email.value=="")
	{	alert("Email cannot be blank. Please enter it.");
		document.aForm.email.focus(); return false;
	}
	
	return true;
}
-->
</script>

<form id='aForm' name="aForm" method='post' action='ingl_payment_gateway.main.php' onsubmit="return validate1()">
<input type='hidden' name='recNo' class='required' value="<?php echo $dbObject->getDbField('recNo');?>">
<input type='hidden' name='kV' value="<?php echo $_REQUEST['kV'];?>">
<table border='0' class='pa-nor'>
<tr><td>
Center :
</td><td>
<select id="centre"  name="centre" class="required">

<?php
$queryB="select * from timesheet_location where status='1' && location='".$_SESSION['branch']."' order by location";
$resultB=mysqli_query($conn,$queryB);
while($numB=mysqli_fetch_array($resultB))
{
if($numB[location]=="S.Extn")
{
$showL="South Extension";
}
else
{
$showL=$numB[location];
}
echo"<option value='".$numB[recNo]."'";
if($dbObject->getDbField('centre')==$numB[recNo]) echo"selected";
echo">".$showL."</option>";
}
?>
</select>
</td></tr>

<tr valign='top'><td>Registration ID</td><td>

<?php			
	$customer= new dbHandler();
        $customer->connect();
        $query_customer="select  a.* from ingl_admission a left join timesheet_location b on a.center_no=b.recNo where b.location='".$_SESSION['branch']."'  order by recNo desc";
		
        $result_customer=$customer->select($query_customer);
	$customer_array=array();
		
		while($data_customer=$customer->SelectNext($result_customer))
              {
		$customer_array[''.$data_customer[recNo].'']="".$data_customer['ref_No']."";
	      }
			  
		$customer_selected=$dbObject->getDbField('Student_id');
		$customer_extra='style="width:180px; height:25px;" onchange="invoice_customer(this.value)"';
			  
		echo select_drop($customer_array,'Student_id','Select',0,$customer_selected,$customer_extra);
			  //print_r($customer_array);
			  
			  
?>
</td><td></td></tr>
<tr valign='top'><td>Name</td><td><input type='text' name='Name' id="cus_name" value="<?php echo $dbObject->getDbField('Name');?>" size='20' maxlength='250'></td><td></td></tr>
<tr valign='top'><td>Amount</td><td><input type='text' name='amount_to_pay' value="<?php echo $dbObject->getDbField('amount_to_pay');?>" size='20' maxlength='250'></td><td></td></tr>
<tr valign='top'><td>Payment Details</td><td><textarea wrap='virtual' rows='3' cols='50' name='payment_details'><?php echo $dbObject->getDbField('payment_details');?></textarea></td><td></td></tr>

<tr valign='top'><td>Address</td><td><textarea wrap='virtual' rows='3' cols='50' name='address' id="cus_address"><?php echo $dbObject->getDbField('address');?></textarea></td><td></td></tr>
<tr valign='top'><td>Email</td><td><input type='text' name='email' value="<?php echo $dbObject->getDbField('email');?>" size='20' maxlength='250'></td><td></td></tr>
<tr valign='top'><td>Mobile</td><td><input type='text' name='mobile' value="<?php echo $dbObject->getDbField('mobile');?>" size='20' maxlength='250'></td><td></td></tr>
<tr><td colspan='3'><input type='submit' name='aC' value='<?php echo $currentMode;?>'></td></tr>
</table>
</form>




<script>
$(function() {
	$('#aForm').validate({
		errorPlacement: function(error, element) 
		{   error.appendTo( element.parent("td").next("td") );
		} 
	});
});
</script>

<?php
// Include footer
include "footer_fd.php";
?>