Naturalmente la devi usare così<?php
if(isset($_POST['textArea']))
{
$string = "";
$count = explode("\n",$_POST['textArea']);
foreach($count as $row)
{
$string .= $row;
}
$check = explode("\n",$string);
var_dump(count($check));
}
?>
<form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post" name="frm">
<textarea name="textArea" cols="50" rows="30">
</textarea>
<input name="submit" type="submit" value="Schizza">
</form>
<?php
$string = "";
if(isset($_POST['textArea']))
{
$count = explode("\n",$_POST['textArea']);
foreach($count as $row)
{
$string .= $row;
}
}
//puoi usare il tag che preferisci
echo "
".$string."</p>";
?>
<form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post" name="frm">
<textarea name="textArea" cols="50" rows="30">
</textarea>
<input name="submit" type="submit" value="Schizza">
</form>![]()