Convert HTML to ASCII

This script converts special HTML characters to their entities version inside user entered data such as a TEXTAREA before the form is submitted. Specifically:

  • ‘<‘ becomes ‘&lt;’
  • ‘>’ becomes ‘&gt;’
  • ‘”‘ (double quote) becomes ‘&quot;’
  • ”’ (single quote) becomes ‘&#039;’
  • ‘&’ becomes ‘&amp;’



Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top