Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Answer: How can I strip away some nested markup code in html by perl, like <SCRIPT> ?

( #6699=categorized answer: print w/ replies, xml ) Need Help??

Q&A > regular expressions > How can use Perl to strip away some nested HTML markup code, like <SCRIPT> ? contributed by chromatic

Unless you're dealing with very simple HTML (either generated by a program or by a beginner), you might discover that these approaches have limited degrees of success. ender's is the best, as it is least greedy.

For all non-trivial HTML parsing, look to CPAN modules: HTML::Parser and HTML::TokeParser.

Comment on Answer: How can I strip away some nested markup code in html by perl, like <SCRIPT> ?
Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (8)
As of 2014-12-28 02:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (178 votes), past polls