Forum Moderators: coopster
like this,
$xyz = mysqli_real_escape_string($con,trim($_POST['xyz']));
but I want to keep the "\r\n" elements . This is because I am replacing these with <br/> so that line breaks appear when the data is displayed
$final_xyz = str_replace("\r\n","<br/>",$xyz);
Now, if I just use trim, the line break thing works. IF mysqli_real... is also used, it doesnt work.
Is it recommended to not use mysqli_re...? for having line breaks in the textarea.
How much of a difference in terms of security issues will it make?
Thanks