The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Perlbug::Interface::Web - Web interface to perlbug database.

DESCRIPTION

Methods for web access to perlbug database via Perlbug module.

SYNOPSIS

        my $o_web = Perlbug::Interface::Web->new;

        print $o_web->top;

        print $o_web->request('help');

        print $o_web->links;

METHODS

new

Create new Perlbug::Interface::Web object.

        my $web = Perlbug::Interface::Web->new;
setup

Setup Perlbug::Interface::Web

    $o_web->setup($cgi);
check_user

Access authentication via http, we just prime ourselves with data from the db as well.

Return menu of system, designed for vertical format. Wraps logo, title and links

        print $o_web->menus();

Return logo of system with href=hard_wired_url

        print $o_web->logo();
get_title

Return title of current page

        print $o_web->get_title();
summary

Return summary of open/closed bugs

        print $o_web->summary();

Return links of system, with adminfaq inserted if appropriate, configured links and object search forms.

        print $o_web->links();
index

Display the index results here...

get_request

Return the req value for this request

        my $req = $self->get_request;
set_command

Set the command type for the rest of the process, based on the input and operation

        my $cmd = $o_web->set_command($req);
commands

Return command menu buttons for request given

        print $o_web->commands($req);
switch

Return appropriate method call for request(else index), using internal CGI object

        my $method = $o_web->switch([$req]); # set $method=($call|index)
start

Return appropriate start header data for web request, includes start table.

        print $o_web->start();
form

Return form with appropriate name and target etc.

        print $o_web->form('menus');
top

Return consistent top of page.

        print $o_web->top($req, $cmd);
request

Handle all web requests (internal print)

        $o_web->request($call);
target2file

Return appropriate dir/file.ext for given target string

        my $filename = $o_base->target2file('header'); 

        # -> '/home/richard/web/header.html'
finish

Return appropriate finishing html

Varies with framed, includes table finish

        print $o_web->finish($req);
overview

Wrapper for doo method

graph

Display pie or mixed graph for groups of bugs etc., mixed to come.

date

Wrapper for search by date access

create

Wrapper for object creation

        $o_web->create($obj, \%data);
object_handler

Wrapper for object access: no ids = search form

        $o_web->object_handler($me_thod, $oid); # o_cgi comes from the heavens
hist

History mechanism for bugs and users.

Move formatting to Formatter::history !!!

headers

Headers for all objects (message, note, ...) by id

        $o_web->headers('patch', $id);  
bidmid

Wrapper for bugid and messageid access

spec

Returns specifications for the Perlbug system.

        $dynamic =~ s/\</&lt;/g;
        $dynamic =~ s/\>/&gt;/g;
        $dynamic =~ s/\b(http\:.+?perlbug\.cgi)\b/<a href="$1">$1<\/a>/gi;
        $dynamic =~ s/\b([\<\w+\-_\.\>|\&.t\;]+\@.+?\.(?:com|org|net|edu))\b/<a href="mailto:$1">$1<\/a>/gi;
webhelp

Web based help for perlbug.

        print $web->webhelp;
mailhelp

Web based mail help for perlbug.

        print $web->mailhelp;
delete

Wrapper for delete access

sql

Open field sql query processor

todo

To do list, may be appended to

adminfaq

adminFAQ

web_query

Form bugid search web query results

# results - don't map to query() unless Base::query modified

Construct search form

        with chosen params as defaults...
update

For all application objects, wraps to object_handler

        $o_web->update(); # args ignored here for passing purposes
current_buttons

Get and set array of relevant buttons by context key

    my @buttons = $o_web->current_buttons('search update reset', scalar(@uids), [$colspan]);
case

Handle case sensitivity from web search form.

format_query

Produce SQL query for bug search from cgi query.

Can be optimised somewhat ...

    my $query = $web->format_query;
wildcard

Convert '*' into '%' for sqlquery

    my $string = $self->wildcard('5.*');
tenify

Create range of links to split (by tens or more) bugids from web query result.

        $self->tenify(\@_bids, 'bug', 7); # in chunks of 7

AUTHOR

Richard Foley perlbug@rfi.net Oct 1999 2000

2 POD Errors

The following errors were encountered while parsing the POD:

Around line 962:

=pod directives shouldn't be over one line long! Ignoring all 10 lines of content

Around line 1290:

=pod directives shouldn't be over one line long! Ignoring all 12 lines of content