Hello, friends!
I have this CSV: AndthiscodeinPHP:
<?php//Createatablefromacsvfile$area=0;echo"<table class=\"table table-hover\">\n\n";
$f = fopen("horarios_modificados.csv", "r", ";");
while (($line = fgetcsv($f)) !== false) {
if($area == 0) echo "<thead>\n";
if($area == 1) echo "<tbody>\n";
$row = $line[0]; // We need to get the actual row (it is the first element in a 1-element array)
$cells = explode(";",$row);
echo "<tr>\n";
foreach ($cells as $cell) {
echo "<td>" . htmlspecialchars($cell) . "</td>\n";
}
echo "</tr>\n";
if($area == 0) echo "</thead>\n";
$area++;
}
fclose($f);
echo "</tbody>\n";
echo "\n</table>\n";
?>
I would like the exclamation point "!" (already inserted in my CSV) was a code in PHP to give new line (line break) in the CSV when in php in the browser.
Could you help me?