The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

WebEditor::OldFeatures::MakeOnePageHTML - create a postscript file from the site

SYNOPSIS

   use WebEditor::OldFeatures::MakeOnePageHTML;
   WebEditor::OldFeatures::MakeOnePageHTML::makeonepagehtml($webeditor_oldcontroller_object, %args);
   WebEditor::OldFeatures::MakeOnePageHTML::makeonepagehtml_send($webeditor_oldcontroller_object, %args);

DESCRIPTION

This module provides the makeonepagehtml function which creates a single page HTML a web.editor site.

HTML TEMPLATES

The HTML templates should be the same as the normal pagetype templates with the suffix _oph.tpl.html instead of .tpl.html. Usually these templates contain only partial HTML without <html>, <head> and <body> tags and should have no navigational elements.

The templates receive the normal parameters as in makehtmlpage and additionally the parameters level (useful in constructing the <h...> tag) and omit_title (true if it is advisable to omit the <h...> tag).

Additionally, the following templates should be defined:

one_page_html_header.tpl.html

The overall header of the HTML document. Here goes the <head> definitions and the opening <html> and <body> tags.

The template receives the normal TemplateVars and additionally the current lang parameter.

one_page_html_footer.tpl.html

The overall footer of the HTML document. Here goes the closing <html> and <body> tags along with footer text for the document.

The template receives the normal TemplateVars and additionally the current lang parameter.

one_page_html_headline.tpl.html

A template for a folder object with no own content. Typically this will contain only one <h...>title</h...> element.

This template receives the normal TemplateVars and additionally the lang, object (the current WE::Obj object), title and level.

FUNCTIONS

The makeonepagehtml function arguments:

-lang => $lang

The language to process. By default the first site language is used.

-debug => $bool

Turn on debug mode if true. This will leave the temporary files after processing and show the command line arguments.

-o => $output_file

Specify an output file. If not set, then the output will be returned by the makeonepagehtml function.

The makeonepagehtml_send function arguments are same as for makeonepagehtml. This function automatically creates an HTTP header and prints the output to STDOUT.

AUTHOR

Slaven Rezic.