VBTK::DynPod2Html - Dynamic Generation of HTML from any POD.


VBTK documentation  | view source Contained in the VBTK distribution.

Index


NAME

Top

VBTK::DynPod2Html - Dynamic Generation of HTML from any POD.

SYNOPSIS

Top

    To come...

DESCRIPTION

Top

This package allows the dynamic generation of HTML from any POD installed in the @INC paths. It is used by the VBTK::Server process to populate the help pages.

METHODS

Top

genPodHtml(<package-name>,<document-root>)

This method takes as input a Perl package name and outputs the HTML as generated by the Pod::Html (Pod::Html) package. The package name can be in the form 'Pkg::SubPkg...' or 'Pkg/SubPkg'. It also strips off any '/' at the beginning or end of the package name, and removes '.html' from the end if found. This allows you to set the 'document-root' to point to a CGI program which calls this method, and then the links in the output HTML will also work.

So for example, if you wrote a cgi named 'dynpod.cgi' and then inside called 'genPodHtml' with the passed package name, and a document-root of 'dynpod.cgi?pkg=', then the links inside the HTML would also call the CGI, passing the appropriate package name to the 'pkg' parm.

findPodFile(<package-name>)

This method searches the @INC paths, looking for the POD file matching the passed package-name. It returns the full path to the file. The first time it is called, it loads a mapping of all packages to POD's into a global package variable, and then refers to that from then on.

SEE ALSO

Top

VBTK
VBTK::Parser
VBTK::ClientObject
VBTK::Server

AUTHOR

Top

Brent Henry, vbtoolkit@yahoo.com

COPYRIGHT

Top


VBTK documentation  | view source Contained in the VBTK distribution.