$text =~ s/|$) # closing script tag or the end of the text ($)
//xgis; # (x) comments (g)lobal, case (i)nsensitive,
# treat string as (s)ingle line
# uncommented version
$text =~ s/|$)//gis;
####
# imagine the following are two consecutive posts on a bulletin board
$first_post = <<_END_;
_END_