CGI::WeT - Suite of modules to themeify a website


NAME

CGI::WeT - Suite of modules to themeify a website


SYNOPSIS

    use CGI::WeT ();

Additional packages may be installed and used. Please check with CPAN for the latest collections.


DESCRIPTION

The collection of CGI::WeT::* modules allows a site to be built from three major components: (1) static themed html files, (2) theme definitions, (3) CGI scripts.

This package (CGI::WeT) will load in the following packages only. No symbols are imported.

    CGI
    CGI::WeT::Engine
    CGI::WeT::Theme
    CGI::WeT::Modules::Basic


Themed HTML

Static files are built with no navigation or other theme-dependent information. The file consists of a set of header lines followed by the body of the file separated by a blank line. For example

    Title: This is an example file
    <p>This file is an example of themed HTML</p>

This will produce a page with `This is an example file' as part of the title in the head and the rest of the file as the body placed on the page according to the theme in force.

CGI::WeT::Engine provides the mod_perl handler for static pages.


Theme Definitions

This part of the package depends on which theme loader is being used. A theme definition provides the engine with the information it needs to produce a well formed page. See the appropriate CGI::WeT::Theme::Loader::*(3) page.


CGI Scripts

CGI::WeT can be used in place of CGI with minor modifications. Replace the use CGI statement with use CGI::WeT at the top of the script and add a line to the close of the script: CGI::WeT-show_page>.

The following is an example based on the CGI.pm book:

  #!/usr/bin/perl
  # Script: plaintext2.pl
  use CGI::WeT ':standard';
  print header('text/html');
  print start_html(-title => 'PlainText2.CGI');
  print "Jabberwock\n\n";
  print "'Twas brillig, and the slithy toves\n";
  print "Did gyre and gimbol in the wave.\n";
  print "All mimsy were the borogroves,\n";
  print "And the mome raths outgrabe....\n";
  print end_html();
  CGI::WeT->show_page;


SEE ALSO

perl(1), CGI::WeT::*(3),

CGI::WeT notes at http://www.jamesmith.com/cgi-wet/


SUPPORT

Please send any questions or comments about CGI::WeT to me at jsmith@jamesmith.com


AUTHORS

 Written by James G. Smith.
 Copyright (C) 1999.  Released under the Artistic License.

 CGI::WeT - Suite of modules to themeify a website