Chirpy!

Latest Version: 0.3
Released: 2007-02-09

Chirpy! 0.3 API Documentation

<<
Chirpy::UI::WebApp

NAME

Chirpy::UI::WebApp - User interface class to use Chirpy! as a Web application

REQUIREMENTS

Apart from a proper Chirpy! installation, this module requires the following Perl modules:

 HTML::Template
 HTTP::Date
 URI::Escape

Optionally, for on-the-fly gzip compression, Compress::Zlib is required. If you wish to use captchas, you will need either Authen::Captcha or GD::SecurityImage.

CONFIGURATION

This module uses the following values from your configuration file:

webapp.webmaster_name

The name of the site's webmaster.

webapp.webmaster_email

The e-mail address of the site's webmaster.

webapp.site_url

The base URL of the web site, i.e. the path to index.cgi, without the trailing forward slash.

webapp.resources_url

The base URL of the path where resources, i.e. publicly available files used by the output pages, are stored, again without the trailing forward slash.

webapp.theme

The identifier of the theme to use.

webapp.welcome_text_file

The name of the file that contains the welcome message to display on the home page. Use a path name relative to the base path defined in the general section.

webapp.cookie_domain
webapp.cookie_path

When cookies are set, these two values are used to limit them to the correct domain name and path. For example, if your QDB is located at http://www.mysite.com/myname/qdb, you would enter mysite.com and /myname/qdb.

webapp.session_expiry

To keep track of users' actions, sessions are used. These are kept around for a while if the user is inactive. This value sets how long they should be saved. You can use a number for the expiry time in seconds, or use a number directly followed by one of these suffixes to indicate time units:

 m: minutes
 h: hours
 d: days
 M: months
 y: years

This format was borrowed from CGI.pm.

webapp.enable_short_urls

If you run Chirpy! on an Apache web server that has the mod_rewrite module installed, you can set this value to 1 to make URLs short, pretty and easy to remember.

webapp.enable_feeds

Set this value to 1 to enable the RSS and Atom feeds the module offers.

webapp.enable_gzip

Apply gzip compression on output if possible.

webapp.captcha_provider

The captcha provider to use. Either Authen_Captcha or GD_SecurityImage, depending on which of the corresponding modules are available. Note that captcha providers may offer additional configuration; see Chirpy::UI::WebApp::Captcha::Authen_Captcha and Chirpy::UI::WebApp::Captcha::GD_SecurityImage. If this parameter is not set, captchas will be disabled.

webapp.captcha_path

The physical path to the directory where public captcha data is to be stored.

webapp.captcha_url

The URL to the captcha path.

webapp.captcha_expiry_time

The number of seconds between the moment when the captcha was generated and the moment when its code expires.

webapp.enable_autolink

Automatically turn hyperlinks and e-mail addresses in quotes into hyperlinks.

LOCALE STRINGS

This module uses the following strings from your locale. Please make sure they are present before using the module.

webapp.start_page_description

Brief description of what the start page does, for tooltips and such.

webapp.start_page_short_title

Abbreviated version of Start Page, e.g. Home, for use in compact menus.

webapp.quote_link_description

Brief description of what a link to the quote is for, for tooltips and such.

webapp.next_page_title

Translation of Next Page, for multi-page quote lists.

webapp.previous_page_title

Translation of Previous Page, for multi-page quote lists.

webapp.current_page_title

Translation of Current Page, for a link to the current page in the event log viewer.

webapp.footer_text

Text stating that the page was generated by Chirpy! and informing the user of the number of milliseconds used to do so. %1% is replaced with the Chirpy! product name and version, linked to the Chirpy! web site, %2% with the number of milliseconds (without a unit).

webapp.footer_text_no_time

Text stating that the page was generated by Chirpy!. %1% is replaced with the string Chirpy!, possibly with formatting.

webapp.manage_quote_instructions

Message explaining to the user that, if he would like to modify or remove a quote, the links to do so are available from the quote list.

webapp.remove_quote_without_viewing_confirmation

Question confirming the removal of a quote by entering its ID and stressing that this is not a recommended action.

webapp.manage_news_instructions

Message explaining to the user that, if he would like to modify or remove a news item, the links to do so are available from the list of recent news items on the start page.

webapp.session_required

Message explaining that the session information cookie that Chirpy! tried to store was not accepted by the user's browser and suggesting that he try again after reviewing his cookie settings.

webapp.timed_out_text

Error message explaining that the connection has timed out while attempting to rate the quote, and asking the user to try again.

webapp.captcha_code_label

The label text for the field where the user fills in the captcha code.

webapp.captcha_image_text

The alternate text for the captcha image.

webapp.minimum_tag_usage_count_title

The title for the tag cloud's slider label, i.e. "Minimum Quotes" followed by a colon.

webapp.top_quote_prefix

The prefix for the "Top Quote" microsummary, i.e. "Top Quote" followed by a colon.

webapp.bottom_quote_prefix

The prefix for the "Bottom Quote" microsummary, i.e. "Bottom Quote" followed by a colon.

webapp.latest_quote_prefix

The prefix for the "Latest Quote" microsummary, i.e. "Latest Quote" followed by a colon.

webapp.latest_unmoderated_quote_prefix

The prefix for the "Latest Unmoderated Quote" microsummary, i.e. "Latest Unmoderated Quote" followed by a colon.

TODO

Split into smaller modules, expose more methods, tons of optimizations.

AUTHOR

Tim De Pauw <ceetee@users.sourceforge.net>

SEE ALSO

Chirpy::UI::WebApp::Session, Chirpy::UI, Chirpy, http://chirpy.sourceforge.net/

COPYRIGHT

Copyright 2005-2007 Tim De Pauw. All rights reserved.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.