Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

pod2html: invalid =item cross-references

by converter (Priest)
on Aug 06, 2003 at 03:15 UTC ( [id://281258]=perlquestion: print w/replies, xml ) Need Help??

converter has asked for the wisdom of the Perl Monks concerning the following question:

I'm having a bit of a problem with pod2html rendering =item cross-references with invalid target fragment names. The following POD snippets demonstrate the problem:

Foo.pod: =head1 Foo stuff Stuff about Foo. =over =item foo see L<Bar/foo> This hack works: L<foo in the Bar manpage|Bar/item_foo> =back Bar.pod: =head1 Bar stuff Stuff about Bar. =over =item foo this item was referenced in Foo. =back

The input PODs are processed with this shell command:

for f in {Foo,Bar}.pod do pod2html \ --htmlroot=file:/ \ --outfile=${f%.pod}.html \ --podpath=$PWD \ --verbose $f done

In Bar.html the A element for the POD =item "foo" is named "item_foo":

<a name="item_foo">foo</a>

Foo.html includes this A element for the cross reference. The target fragment name is "foo", but it seems that it should be "item_foo":

see <a href="file:///home/me/perltestlib/DST/XBase/Bar.html#foo">foo i +n the Bar manpage</a>

The reference listed after "This hack works" produces the desired output:

<a href="file:///home/me/perltestlib/DST/XBase/pod_problem/Bar.html#it +em_foo">foo in the Bar manpage</a>

perl is version 5.8.0 (Linux).

I know I've probably ventured into "there are better alternatives to Pod::Html" territory, but am I missing or misunderstanding something in the documentation, or is the aforementioned workaround the only way to get valid =item cross-references?

converter

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://281258]
Approved by antirice
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (8)
As of 2024-04-25 15:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found