Please Enter a Search Term

$value) { if ($value=="on" || $value=="of") { $somecontent.= $value . "n"; } elseif ($value=='update' || $value=='Update') { } else { $somecontent.= $value . ","; } } $handle=fopen($ff, "w+"); if (fwrite($handle, $somecontent) === FALSE) { echo "Cannot write to file ($ff)"; exit; } fclose($ff); } display_file($ff); //Functions------------------------ function display_file($file){ //Put file into $contents $contents = file_get_contents($file); //Split each file row into an array value $contents=explode("n",$contents); // You could try using $PHP_SELF instead of $_SERVER['PHP_SELF'], but if the page is only being accessed through IE you can just leave it. $i=0; echo "

"; echo " "; foreach ($contents as $item){ $person=explode(",",$item); if ($person[0]=="" || $person[2]==""){ } else { echo " "; echo " "; $i+=1; } } // Put the Update button under it all echo " "; echo "
Employee Reason In/Out of Office
$person[0] "; if (substr($person[2],0,2)=='on') { $mark1='CHECKED'; $mark2=''; } else { $mark1==''; $mark2='CHECKED'; } echo " In Out

"; }

Share