Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

Re: Help with HTML::StripScripts::Parser

by ww (Archbishop)
on Aug 07, 2012 at 20:15 UTC ( #986071=note: print w/replies, xml ) Need Help??

in reply to Help with HTML::StripScripts::Parser

Perhaps you should familiarize yourself with html and attributes, generally.

You can't have bare attributes. You can put them in a <span class="...">Clear Up...</span> tag-pair in some cases, including this one, but stand-along attributes will merely be rendered as ordinary content in the user's browser.

  • Comment on Re: Help with HTML::StripScripts::Parser

Replies are listed 'Best First'.
Re^2: Help with HTML::StripScripts::Parser
by tobyink (Abbot) on Aug 07, 2012 at 20:35 UTC

    "You can't have bare attributes."

    I don't think the OP wanted to have bare attributes replacing the <h3> tag. I think the OP was concerned about the class attributes disappearing from the other elements, such as <ol>. That was my reading of the question anyway.

    perl -E'sub Monkey::do{say$_,for@_,do{($monkey=[caller(0)]->[3])=~s{::}{ }and$monkey}}"Monkey say"->Monkey::do'
      I found a solution maybe not the best but works
      $HTML =~ s/<h2[^)]*h2>//g;
      No more H2 tags and class attributes OK

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://986071]
[prospect]: And it was great because I'm using the book as well, to get some more examples or extra information
[ambrus]: Ask merlyn directly. Maybe he has copies.
[ambrus]: write him an email or something
[prospect]: ok I will

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (7)
As of 2017-09-25 10:34 GMT
Find Nodes?
    Voting Booth?
    During the recent solar eclipse, I:

    Results (279 votes). Check out past polls.