Jump to content

change html and mysql characters in text to insert it to mysql


aliento

Recommended Posts

You want to display ">"? You use htmlentities when display the data to the user.

 

Take this for example:

 

<?PHP

  $HTML = '<span> THIS IS HTML </span>';
 
  echo 'Will not display ">" - '. $HTML;
 
  echo '<br> ------------------------- <br>';
 
  echo 'Will display ">" - '. htmlentities($HTML);
 
?>

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.