<?php$data = "date: ".$_POST['date'];$filearray = fopen("filename","r") or exit("Unable to open file!");while(!feof($filearray)){$val = fgets($filearray);$val = trim($val);if ($data == $val){$flag=1;print "Data on $data <br/>";echo "===================================================================================================================================================<br/>";for($i=1;$i<=39;++$i){echo fgets($filearray). "<br/>";}}}fclose($filearray);if($flag != 1)print "Date not found OR wrong date format! <br/> kindly use yyyy-mm-dd format!<br/>";?>