WebsiteBaker 2.13.9 is now available!
R.I.P Dietmar (luisehahne) and thank you for all your valuable work for WBhttps://forum.websitebaker.org/index.php/topic,32355.0.html
$returnvalue = "";$filepath = WB_PATH.MEDIA_DIRECTORY.'/'.$file;$fileurl = WB_URL.MEDIA_DIRECTORY.'/'.$file;if(file_exists($filepath)) { $lines = file($fileurl); if (!empty($class)) $tableclass = " class=\"$class\""; if (!empty($id)) $tableid = " id=\"$id\""; $returnvalue .= '<table'.$tableclass.$tableid.">\n"; foreach ($lines as $line_num => $line) { $returnvalue .= "<tr>\n"; $data = explode("\t", $line); foreach ($data as $cell) { if (($line_num===0) && ($headerrow==="TRUE")) {$returnvalue .= '<th>'.$cell."</th>\n";} else {$returnvalue .= '<td>'.$cell."</td>\n";} } $returnvalue .= "</tr>\n"; } $returnvalue .= "</table>\n"; }else {$returnvalue = "File not found - ". $filepath;}return $returnvalue;
First Name{TAB}Last Name{TAB}Age{TAB}Gender{TAB}TimeBob{TAB}White{TAB}31{TAB}M{TAB}18:37Betty{TAB}Wont{TAB}32{TAB}F{TAB}19:50Justin{TAB}Case{TAB}50{TAB}M{TAB}22:12
Results from the Test My Patience 5K run:[[TabTextToHTMLTable?file=Results.txt&class=stripe&headerrow=TRUE]]