Konstrukt::Plugin::blog - Konstrukt blogging engine
<& blog / &>
This Konstrukt Plug-In provides blogging-facilities for your website.
You may simply integrate it by putting
somewhere in your website.
To show a form to filter the entries put
<& blog show="filter" / &>
in your page source.
If you want to get your content as an RSS 2.0 compliant XML file you may want to put
<& blog show="rss2" / &>
alone in a separate file.
If you want to allow trackbacks to your blog entries, you have to to put
<& blog show="trackback" / &>
alone in a separate file, which you should advertise as the trackback ping URL.
The HTTP parameters "email" and "pass" will be used to log on the user before retrieving the entries. This will also return private entries.
http://domain.tld/blog_rss2.ihtml?email=foo@bar.baz;pass=23
You may do some configuration in your konstrukt.settings to let the plugin know where to get its data and which layout to use. Default:
#backend blog/backend DBI #layout blog/entries_per_page 5 blog/template_path /templates/blog/ #user levels blog/userlevel_write 2 blog/userlevel_admin 3 #rss export blog/rss2_template /templates/blog/export/rss2.template blog/rss2_entries 20 #number of exported entries #prefix for cached rendered article markup blog/cache_prefix blog_article_cache/ #use a captcha to prevent spam blog/use_captcha 1 #you have to put <& captcha / &> inside your add-template #the content type of the entries. #will be sent to trackback services. blog/trackback/content_type utf-8 #permalink URI to your blog entries. #will be sent to the pinged sites. the parameter ?action=show;id=42 with the correct id of the entry will be appended. #by default, this setting is undefined and the plugin tries to guess the right permalink, what may fail blog/trackback/permalink http://your.site/blog/
See the documentation of the backend modules (e.g. "CONFIGURATION" in Konstrukt::Plugin::blog::DBI) for their configuration.
Yes, this plugin may return dynamic nodes (i.e. template nodes).
Initializes this object. Sets $self->{backend} and $self->{template_path}. init will be called by the constructor.
Installs the templates.
Parameters:
none
Prepare method
$tag - Reference to the tag (and its children) that shall be handled.
All the work is done in the execute step.
Displays the form to add an article.
Takes the HTTP form input and adds a new blog entry.
Desplays a confirmation of the successful addition or error messages otherwise.
Accepts the blog entry's content and trackback links, tries to discover trackbacklinks from the pages linked in the content and sends pings to all websites, that have been referenced.
$id - The id of the blog entry.
$title - The title of the blog entry.
$excerpt - The description/excerpt of the blog entry.
$content - The content of the blog entry, that may contain links to websites, for which a trackback autodiscovery may be performed.
$trackback_discovery - True, if autodiscovery should be performed.
$trackback_links - The newline-separated trackback-links that have been explicitly specified by the user
Generates a permalink to a blog entry using the settings or guessing it.
Grabs the article from the backend and puts it into a form from which the user may edit the article.
Displays the form to edit an article.
Takes the HTTP form input and updates the requested blog entry.
Displays a confirmation of the successful update or error messages otherwise.
Displays the confirmation form to delete an article.
Deletes the specified entry.
Displays a confirmation of the successful removal or error messages otherwise.
Shows the requested blog entry including its comments
Displays the entry or error messages otherwise.
$id - ID of the entry to show (optional)
Shows the blog entries
Displays the entries or error messages otherwise.
Take plain text and formats it using the wiki plugin. Caches the result. If a cached file already exists, the cached result will be used.
Returns a field tag node contatining the formatted output nodes.
$id - The ID of the article
$content - The (plaintext) content
Deletes the content cache for a given article
Takes the specified entry ID or HTTP form input and shows the form to add a comment.
Displays the form to add a comment.
$id - ID of the entry, which shall be commented. (optional)
Takes the HTTP form input and adds a new comment.
Displays a confirmation of the successful addition or error messages otherwise.
Takes the HTTP form input and removes an existing comment.
Displays the form to select articles.
Generates an RSS 2.0 compliant XML file with the content from the database.
Pings a specified trackback address with the specified information.
Returns true on success, false otherwise.
$url - The URL of the trackback link
$info - The information about the pinging article. A hashref containing this information:
{ url => 'URL of the entry (required)', title => 'Title of the entry (optional)', excerpt => 'Excerpt of the entry (optional)', blog_name => 'Name of the blog (optional)', }
Downloads a blog entry and tries to discover the trackback link to this entry.
Returns the URL of the trackback link on success, undef otherwise.
$url - The URL of the blog entry
Processes an incoming trackback request. The ID of the blog entry must be specified as an URL parameter:
http://your.site/blog/trackback/id=42
Returns the appropriate response to the client.
Parameters: none
Takes the HTTP form input and removes an existing trackback.
Copyright 2006 Thomas Wittek (mail at gedankenkonstrukt dot de). All rights reserved.
This document is free software. It is distributed under the same terms as Perl itself.
Konstrukt::Plugin::blog::DBI, Konstrukt::Plugin, Konstrukt
To install Konstrukt, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Konstrukt
CPAN shell
perl -MCPAN -e shell install Konstrukt
For more information on module installation, please visit the detailed CPAN module installation guide.