libwww-perl / libwww-perl/HTML-Parser
Make iframe parsing configurable [rt.cpan.org #46099]
Nobody has claimed this yet.
- Dominant language
- Perl
- Stars
- 7
- Forks
- 15
- Avg merge
- 12h 8m
- Merged PRs (30d)
- 2
Description
Migrated from rt.cpan.org#46099 (status was 'open')
Requestors:
- bdfoy@cpan.org
From bdfoy@cpan.org on 2009-05-15 06:15:45
:
Since the latest versions of HMTL::Parser do not parse the content of
iframes, some of my applications using HTML::SimpleLinkExtor have
broken. The text between the iframe tags is what the browser displays
and is usually more HTML, and I need to be able to extract any links in
that text.
I'd like to at least be able to turn on parsing for iframes, even if it
is off by default.
From gaas@cpan.org on 2009-06-20 09:17:40
:
On Fri May 15 02:15:45 2009, BDFOY wrote:
> Since the latest versions of HMTL::Parser do not parse the content of
> iframes, some of my applications using HTML::SimpleLinkExtor have
> broken. The text between the iframe tags is what the browser displays
> and is usually more HTML, and I need to be able to extract any links in
> that text.
Browsers that support iframes are supposed to ignore everything inside the iframe. They are
supposed to render the HTML found at the 'src' location.
> I'd like to at least be able to turn on parsing for iframes, even if it
> is off by default.
I see the point if you need to emulate the behaviour of very old browsers.
A workaround is to invoke a subparser on the iframe content text. I'll see if I find an easier
way to do this.
From gaas@cpan.org on 2009-06-20 09:24:09
:
The TODO file has this entry:
- make literal tags configurable. The current list is hardcoded to be "script", "style", "title",
"iframe", "textarea", "xmp", and "plaintext".
which would be my preferred way to fix this.
From jwilliams@cpan.org on 2011-09-20 17:20:09
:
Making literal tags configurable would also be useful for those doing
javascript templates with <script type="text/html"> tags.
From andrew@pimlott.net on 2012-10-17 22:22:02
:
On Sat Jun 20 05:17:40 2009, GAAS wrote:
> > I'd like to at least be able to turn on parsing for iframes, even if
> it
> > is off by default.
>
> I see the point if you need to emulate the behaviour of very old
> browsers.
What is the point of not parsing the content of iframes? I can't find
any justification, and it seems at odds both with the spec and user
expectations. Removing this special case would make HTML::Parser simpler
and more uniform.
Andrew
From gaas@cpan.org on 2012-10-18 22:09:53
:
I explained the point just above the text you quoted. What's "the spec" you'r
refering to?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the TODO file entry about making literal tags configurable, then inspect how HTML::Parser currently handles iframe and the other listed literal tags. Clarify whether the intended result is configurable parsing or removal of the iframe special case, and verify the chosen behavior with parser tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- perl
- Domain
- web-dev
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100