<?php
require_once('functions.php');
  
//if (isset ($_POST['id']) && is_numeric($_POST['id']) {
	$lab_id=$_POST['id'];
//	$_SESSION['qd']=$pl_id;
//	$vd=$_SESSION['lands'];
	//echo $pl_id;
//}
   $con=mysqli_connect("localhost","gurudumu_bazuu2","@@karishop@@2023!!","gurudumu_pos");
$fg=mysqli_query($con,("select concat_ws(' ',first,last)as name,wage  from labor where lab_id='$lab_id'"));
  $vu=mysqli_fetch_array($fg);
  $name=$vu['name'];
     $wage=$vu['wage'];
       $id=$lab_id;
       $_SESSION['wage']=$wage;
         $_SESSION['name']=$name;
   $_SESSION['id']=$id;
     //if(mysqli_num_rows($fg)==0){
		$url='lones.php';
	// }
  ob_end_clean();
header("Location: $url");
mysqli_close($con);
  ?>