HTML::...:WebApp(3pm)
β¨ NAME β¨
HTML::WikiConverter::WebApp β bestie, it's a whole web interface to HTML::WikiConverter π
π SYNOPSIS π
okay so this lives inside the index.cgi instance script (which ships with this distribution, iconic of them honestly):
#!/usr/bin/perl
use HTML::WikiConverter::WebApp;
my %config = (
template_path => '/path/to/web/templates',
);
HTML::WikiConverter::WebApp->new( PARAMS => \%config )->run;
π DESCRIPTION π
This module gives you a CGI::Application interface to HTML::WikiConverter and all installed dialect modules. every single one you've got. no cap π«Ά
For installation instructions, go read the INSTALL file. periodt.
πΈ QUERY PARAMETERS πΈ
This app takes a bunch of query parameters to control how it behaves. The most basic one is the run mode parameter, m. This application can be in one of two run modes: new or convert. (These correspond to the new_page() and output_page() methods, respectively, iykyk.) new causes a new page to be displayed, while convert displays the results of html-to-wiki conversion. π¦
Additional query parameters can be passed independent of run mode:
source_typeβ one ofraw_html,from_uri, orsample_html.dialectβ any installed dialect, egMediaWiki.base_uriβ base URL to be used for converting relative links to absolute ones.wiki_uriβ template for wiki URLs. When scanning the HTML source, if a URL (as in ana hreforimg srcattribute value) is found matching this template, it will be treated to a link to a wiki article/image. ConsultATTRIBUTESin HTML::WikiConverter for more information.
Note that this is a bit less flexible than using the wiki_uri attribute directly in HTML::WikiConverter. That attribute allows multiple templates, allows coderefs, and regexps, etc. This option only accepts a single scalar representing a very simple wiki URL template.
show_parsed_htmlβ if enabled, an additional textarea containing the parsed HTML will be displayed. extra content, we love her β¨escape_entitiesβ if enabled, unsafe HTML entities (<,>, and&) will be encoded using HTML::Entities.formatβ one ofhtmlorxml. Determines the type of output displayed by this application.
π¦ METHODS π¦
setup
Sets up the app for CGI::Application.
new_page
Corresponds to the new run mode. Returns a blank form. If arguments are available on the CGI query string, these are used as default values for the form fields.
output_page
Corresponds to the convert run mode. Same as new_page() but returns the wiki markup for the provided html as well.
load_template
Loads the specified HTML::Template template.
display_error
Error-catching method called by CGI::Application if a run mode fails for any reason. Displays a basic form with a styled error message up top. π
π AUTHOR π
David J. Iberri, "<diberri at cpan.org>"
π BUGS π
Please report any bugs or feature requests to "bug-html-wikiconverter at rt.cpan.org", or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=HTML-WikiConverter. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes. fr fr, the notification pipeline is real. π₯
π«Ά SUPPORT π«Ά
You can find documentation for this module with the perldoc command.
perldoc HTML::WikiConverter::WebApp
You can also look for information at:
- AnnoCPAN: Annotated CPAN documentation
http://annocpan.org/dist/HTML-WikiConverter-WebApp
- CPAN Ratings
http://cpanratings.perl.org/d/HTML-WikiConverter-WebApp
- RT: CPAN's request tracker
http://rt.cpan.org/NoAuth/Bugs.html?Dist=HTML-WikiConverter-WebApp
- Search CPAN
http://search.cpan.org/dist/HTML-WikiConverter-WebApp
π COPYRIGHT & LICENSE π
Copyright (c) David J. Iberri, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
and that's the whole page, bestie π this one's from perl v5.34.0, dated 2022-06-14, and it's filed under the User Contributed Perl Documentation shelf in HTML::...:WebApp(3pm). go forth and convert some wikis πΈπ
π¦ where this page comes from
- debian bookworm: libhtml-wikiconverter-perl 0.68-4 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- debian trixie: libhtml-wikiconverter-perl 0.68-4 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libhtml-wikiconverter-perl 0.68-4 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libhtml-wikiconverter-perl 0.68-4 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libhtml-wikiconverter-perl 0.68-4 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms