in reply to My Regex Won't Work . . .

You should have a look at the HTML::Strip module, it does a good job at stripping HTML tags.

As for your immediate problem...
my $str = do { local $/; <DATA> }; $str =~ s!<(script|style|option|textarea)[^>]*?>.*?</\1[^>]*?>!!gsi; # In fact when you turn on the non-greedy match with '?', you # don't need the [^>] either... So the following regex works # equally well: # $str =~ s!<(script|style|option|textarea).*?>.*?</\1.*?>!!gsi; print "$str\n"; __DATA__ <script> This is removed. </script> This is not removed.