Doesn't the following work?
$content =~ s/&/&/g; $content =~ s/</</g; $content =~ s/>/>/g; # optional. print("<textarea>$content</textarea>");
To save it:
open(FILE, "> file.html"); print FILE $cgi->param('content'); close(FILE);
In reply to Re: escaping <!-- and --> in substitution...or other help plz
by ikegami
in thread escaping <!-- and --> in substitution...or other help plz
by Stenyj
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |