Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perlvar.pod incorrect link #16652

Closed
p5pRT opened this issue Aug 8, 2018 · 6 comments
Closed

perlvar.pod incorrect link #16652

p5pRT opened this issue Aug 8, 2018 · 6 comments

Comments

@p5pRT
Copy link

p5pRT commented Aug 8, 2018

Migrated from rt.perl.org#133432 (status was 'open')

Searchable as RT133432$

@p5pRT
Copy link
Author

p5pRT commented Aug 8, 2018

From @Grinnz

The link in the @​{^CAPTURE} section to $<digits> is not correct. It's
currently L</$I<digits>> which ends up linking to $digits (which doesn't
exist). The correct link would currently be​:

L<<< /$<I<digits>> ($1, $2, ...) >>>

@p5pRT
Copy link
Author

p5pRT commented Aug 12, 2018

From @jkeenan

On Wed, 08 Aug 2018 20​:58​:44 GMT, grinnz@​gmail.com wrote​:

The link in the @​{^CAPTURE} section to $<digits> is not correct. It's
currently L</$I<digits>> which ends up linking to $digits (which doesn't
exist). The correct link would currently be​:

L<<< /$<I<digits>> ($1, $2, ...) >>>

I tried out your suggestion in this branch​:

jkeenan/dbook/133440-perlvar

I ran the revised file through pod2html. When I clicked on the resulting hyperlink, it did not jump to the intended location.

(I tried out a couple of other things, which created a jumpable link but failed to pass t/porting/podcheck.t.)

Suggestions?

--
James E Keenan (jkeenan@​cpan.org)

@p5pRT
Copy link
Author

p5pRT commented Aug 12, 2018

The RT System itself - Status changed from 'new' to 'open'

@p5pRT
Copy link
Author

p5pRT commented Aug 12, 2018

From @Grinnz

On Sun, Aug 12, 2018 at 11​:23 AM James E Keenan via RT <
perlbug-followup@​perl.org> wrote​:

On Wed, 08 Aug 2018 20​:58​:44 GMT, grinnz@​gmail.com wrote​:

The link in the @​{^CAPTURE} section to $<digits> is not correct. It's
currently L</$I<digits>> which ends up linking to $digits (which doesn't
exist). The correct link would currently be​:

L<<< /$<I<digits>> ($1, $2, ...) >>>

I tried out your suggestion in this branch​:

jkeenan/dbook/133440-perlvar

I ran the revised file through pod2html. When I clicked on the resulting
hyperlink, it did not jump to the intended location.

(I tried out a couple of other things, which created a jumpable link but
failed to pass t/porting/podcheck.t.)

Suggestions?

I think this is a bug in Pod​::Simple​::HTML, I don't know if there is a way
to generate a link to that anchor. In Pod​::Simple​::XHTML, which is used by
most websites rendering perldocs now, the mentioned link tag works.

perl -MPod​::Simple​::XHTML -E'my $parser = Pod​::Simple​::XHTML->new;
$parser->anchor_items(1); $parser->parse_string_document("=pod\n\nL<<<
/\$<I<digits>> (\$1, \$2, ...) >>>\n\n=over\n\n=item \$<I<digits>> (\$1,
\$2, ...) >>>\n\n=back")'

-Dan

1 similar comment
@p5pRT
Copy link
Author

p5pRT commented Aug 12, 2018

From @Grinnz

On Sun, Aug 12, 2018 at 11​:23 AM James E Keenan via RT <
perlbug-followup@​perl.org> wrote​:

On Wed, 08 Aug 2018 20​:58​:44 GMT, grinnz@​gmail.com wrote​:

The link in the @​{^CAPTURE} section to $<digits> is not correct. It's
currently L</$I<digits>> which ends up linking to $digits (which doesn't
exist). The correct link would currently be​:

L<<< /$<I<digits>> ($1, $2, ...) >>>

I tried out your suggestion in this branch​:

jkeenan/dbook/133440-perlvar

I ran the revised file through pod2html. When I clicked on the resulting
hyperlink, it did not jump to the intended location.

(I tried out a couple of other things, which created a jumpable link but
failed to pass t/porting/podcheck.t.)

Suggestions?

I think this is a bug in Pod​::Simple​::HTML, I don't know if there is a way
to generate a link to that anchor. In Pod​::Simple​::XHTML, which is used by
most websites rendering perldocs now, the mentioned link tag works.

perl -MPod​::Simple​::XHTML -E'my $parser = Pod​::Simple​::XHTML->new;
$parser->anchor_items(1); $parser->parse_string_document("=pod\n\nL<<<
/\$<I<digits>> (\$1, \$2, ...) >>>\n\n=over\n\n=item \$<I<digits>> (\$1,
\$2, ...) >>>\n\n=back")'

-Dan

@khwilliamson
Copy link
Contributor

The link was, apparently without noticing this ticket, changed to what @Grinnz suggested, and it passed podcheck.

If there is a Pod::Simple bug, a ticket should be opened in its queue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants