I'm using search and replace to solve this issue unless someone else have a better idea. Thanks.
my $removeText="<script> type="text/javascript">function....</script>"; $string = ~s/$removeText//gi; --- On Mon, 1/19/09, Bobby <cybercruis...@yahoo.com> wrote: > From: Bobby <cybercruis...@yahoo.com> > Subject: Removing block of text in string > To: beginners@perl.org > Date: Monday, January 19, 2009, 12:00 PM > Hi, > > I have a javascript function in my long text string that i > want to remove, how do i remove a text string from starting > point to an ending point so that the javascript block > <script> to </script> is remove from my text > string? Thanks. > > Current: > string = "this is my text string <script > type="text/javascript">function....</script> > blah blah..." > > Desired Result: > string = "this is my text string blah blah..." > > > > > > > -- > To unsubscribe, e-mail: beginners-unsubscr...@perl.org > For additional commands, e-mail: beginners-h...@perl.org > http://learn.perl.org/ -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/