1HTML::TokeParser::SimplUHesT:eM:rLT:oC:koTenontk:re:iPPbarurotsceeedrs:sP:IeSnrislmtprDluoecc:tu:imToeonnk(te3anpt:mi:)oPnrocessInstruction(3pm)
2
3
4
6 HTML::TokeParser::Simple::Token::ProcessInstruction - Token.pm process
7 instruction class.
8
10 use HTML::TokeParser::Simple;
11 my $p = HTML::TokeParser::Simple->new( $somefile );
12
13 while ( my $token = $p->get_token ) {
14 # This prints all text in an HTML doc (i.e., it strips the HTML)
15 next unless $token->is_text;
16 print $token->as_is;
17 }
18
20 Process Instructions are from XML. This is very handy if you need to
21 parse out PHP and similar things with a parser.
22
23 Currently, there appear to be some problems with process instructions.
24 You can override this class if you need finer grained handling of
25 process instructions.
26
27 is_pi() and is_process_instruction() both return true.
28
30 • get_token0
31
32 • is_pi
33
34 • is_process_instruction
35
36 • return_token0
37
38
39
40perl v5.38.0 HTML::TokePa2r0s2e3r-:0:7S-i2m0ple::Token::ProcessInstruction(3pm)