<?php 	include_once('../../config.php');   	
		include_once(ABS_PATH.'/admin/login_check.php');    
?>  
<?php  include ABS_PATH.'/admin/header.php';	?>  

<script>
var URL  = '<?php echo ROOTPATH;?>';  
function del_record(val)
{

    
	var r = confirm("Do you really want to delete record !");
	if (r == true) {    
	$.ajax({
	type: 'POST',
	    url: URL+"/admin/ajax/default.php",
	//async: false,			 
	data: {del_Pin:1,val:val},	  
	success: function(ajaxresult){	     
		location.reload();	 	
	},
	error: function(XMLHttpRequest, textStatus, errorThrown) { 
	alert('Error');
	}
	});
	
	}	
	
}

</script>
		 
		<div class="col-md-10">  
  			<div class="content-box-large">
  				<div class="panel-heading">
					<div class="panel-title"><h3> Daily Pay News</h3></div>
					
					<div align="right"> 
					     
					</div>
					
				</div>
				
  				<div class="panel-body">
  					<table cellpadding="0" cellspacing="0" border="0" class="table table-striped table-bordered" id="example">
						<thead>
							<tr>
								<th>News</th> 
								<th>Status</th> 
								<th>Action</th>   
							</tr>
						</thead>
						<tbody>
						 
						    <?php 
                                    $stmt=$conn->prepare("select *  from UI__News     ");     
                                    $stmt->execute(); 
                                    $UI__WithDraw = $stmt->fetch(PDO::FETCH_OBJ);     
						    ?>
				        	<tr class="odd gradeX">
								 
								<td><?php echo $UI__WithDraw->news;?></td> 
								<td><?php if($UI__WithDraw->is_active==1) echo "Active"; else echo "Inactive";  ?></a></td> 
								<td><a href="editNews.php?id=<?php echo $UI__WithDraw->id;?>">Edit</a></td> 
							</tr>
							
							<?php 
                                    $stmt=$conn->prepare("select *  from UI__News    where  typ=1  ");     
                                    $stmt->execute(); 
                                    $UI__WithDraw = $stmt->fetch(PDO::FETCH_OBJ);     
						    ?>
							
							<tr class="odd gradeX">
								 
								<td><?php echo $UI__WithDraw->news;?></td> 
								<td><?php if($UI__WithDraw->is_active==1) echo "Active"; else echo "Inactive";  ?></a></td> 
								<td><a href="editNews.php?id=<?php echo $UI__WithDraw->id;?>">Edit</a></td> 
							</tr>
							
							 
						</tbody>
					</table>
  				</div>
  			</div>



		  </div>
		</div>
    </div>

<?php  include ABS_PATH.'/admin/footer.php';	?>    