Recent Changes - Search:

Cookbook

PmWiki

pmwiki.org

BlogIt

Summary: Provides a complete blogging system, using in-built PmWiki features -- additional features are supported through existing cookbooks.
Version: 1.4.0 (14-Mar-2010)
Prerequisites: PmWiki 2.2.1 or later, PmForm, Javascript enabled on browser for Admin and Blog entry functions.
Status: Active
Maintainer: DaveG

Project Blog: http://solidgone.org/Tags/Blogit

Categories: Blog
Download: blogit.zipΔ
License: Dual licensed under the MIT and GPL licenses.
Users: +8 (View / Edit)

Update Summary 1.4.0 (14-Mar-2010)

  • Many Admin functions are now 'ajax' based, and are much quicker, being performed without reloading the page (ajax). (Currently comment un/approve, comment delete, comment block, entry delete, comment and blog entry form validation.)
  • Added link to block commenter IP address if BlockList is being used ($EnableBlocklist).
  • Field validation is now done in the browser, so error messages are seen immediately.

For more information refer to the full release details.

If you're upgrading from a previous beta release, make sure you refer to the change highlights for prior versions, particularly release 1.2.0, and release 1.1.0.

Description

BlogIt provides the core features demanded of a blogging system, including blog entry, blog management, comment entry and approval, and comment management, and comes with pagelists providing most features provided in other blog systems. Additional features like ping-backs, notifications, RSS feeds, and tag-clouds, can be added using existing cookbooks. The system is written using only existing PmWiki features, and requires no additional cookbooks. Code has been kept to a bare minimum to ensure survivability.

BlogIt works with all existing skins. Some skins provide an additional features when used with BlogIt, like Blix, Equilibrium, DropShadow, GlossyHue, and others. Simply install and activate the skin and BlogIt will put blog entry elements like Title, date, author, tags in the right locations for the skin design. All other skins will work with BlogIt -- but you won't get the automatic styling of some blog elements, unless the skin accommodates that.

Feature Summary

BlogIt provides an easy to setup blogging system, based on PmWiki, providing similar functionality to other major blogging platforms.

Writing

  • Author friendly blog entry.
  • Blog entries can have a status of Published, Draft, or Sticky.
  • Provide blog introductions with a "Read more..." link.
  • Full blog entry tagging, including links to view all blog entries with specific tag.
  • Blog entries can be dated, indepently of actual save date, including future dates.

Commenting

  • Blog readers can add comments to blog entries.
  • Comments can be automatically approved, or can be manually approved by an administrator after review.
  • Comment approval and captcha reduce coment spam.
  • Admins can quick add commenters to the Blocklist, or simply delete the comment.
  • Comments can be Open, Read Only, or None for each blog entry, and also disabled for the entire blog.
  • Easy access to all unapproved comments.

Administration

  • Control panel provides quick access to blogs and comments, with links for editing and deleting.
  • Quick link to add new blog entries.
  • List all recent blog entries, or view entries in published, draft, and stickies status.

Other Features

  • SEO friendly url support.
  • Pre-created pagelists give easy access to recent blog entries, recent comments, and tags.
  • Pagination support: Include a user-definable maximum number of entries per page, with next/prev links.
  • Ability to have more than one blog.
  • Blogs entries can exist in any group, with no naming restrictions.
  • BlogIt works with any PmWiki skin. But some skins provide an additional layout layer that provides additional styling of page-level attributes.
  • Conversion utility to convert existing pages to/from BlogIt.
  • All the power offered by PmWiki, including file based data storage (so no database), cross-site deployment, and easy extensibility.

Demo

A demo sandbox is available at solidgone.org. Admin password is "blogadmin", and the Edit password is "blogedit" -- no user name is needed. Feel free to add new blog entries, add comments, login as admin and approve a few comments.

You can also see BlogIt in action at my personal journal and my tech journal. BlogIt has now replaced my use of Drupal.

Comments

Show your support and leave a comment, or help out and let me know if you have a suggestion or a problem. Love it or hate it, I'd like to know!

Download and Install

  1. Prep: Ensure PmForm is available in your cookbook directory (usually pmwiki/cookbook/). There are two files in the PmForm ZIP file. You need to put pmforms.php direct into your cookbook/ directory. Site.PmFormTemplates is not needed for BlogIt, but should be put into your wikilib.d directory. You do not need to add an include_once pmforms.php from config.php -- BlogIt will automatically do the include for you.
  2. Download (blogit.zipΔ).
    1. Unzip the contents of the cookbook folder into your cookbook directory, usually pmwiki/cookbook/.
    2. Unzip the contents of the pub folder into your pub directory, usually pmwiki/pub.
  3. Security:
    1. Make sure you assign Edit and Admin passwords. If you don't anyone will be able to create blog entries, and to post comments.
      $DefaultPasswords['admin'] = crypt('your_admin_password');
      $DefaultPasswords['edit'] = crypt('your_edit_password');
      
    2. Set $bi_AuthPage Permissions: If you are using the standard PmWiki security (not AuthUser, etc), then ensure Edit permissions are set on the page "Blog.Main".
  4. Config:
    1. Ensure that $EnableRelativePageVars = 1; is set. This is normally set by default.
    2. Add the following to your local configuration file, usually pmwiki/local/config.php. You need to put this towards the end of config.php@], after password definitions, and also after any of the optional configuration steps:
      $MaxIncludes=500;  #BlogIt makes heavy use of includes, so this needs to be increased.
      include_once("$FarmD/cookbook/blogit/blogit.php");
      

Optional Setup

These steps need to come before the BlogIt include statement.

  1. Captcha: (optional) If you want to use captcha to prevent comment spam, then refer to the Stop Spam section.
  2. Caching: (optional) Caching speeds up PmWiki generally, and therefore BlogIt. But it can delay the appearance of new comments and blog entries in pagelists.
    1. Create a work.d directory at the same level as your wiki.d directory, usually pmwiki/work.d/.
    2. These settings enable caching:
      $WorkDir = dirname(__FILE__).'/../work.d';
      $PageListCacheDir = $WorkDir .'/';
      $EnablePageIndex=1;
      
  3. Skins: (optional) If the skin you use does not provide support for BlogIt, it will still work. However, the elements on the page generated by BlogIt will have a default styling. If the skin does not provide explicit BlogIt support, check the skinning section to see if there is a stylesheet, which will improve the appearance of your blog. If the skin you use does not provide styling let me know on the comment page.
  4. Define a default group for blog entries -- used as the default in the "Page URL" field when creating a new blog entry (purely for convenience, not required):
    $bi_DefaultGroup='Blog';
  5. Specify which groups to look for blog entries (may make things quicker on large sites). If you want blog entries to exist in any group, then set this parameter to an empty string. If you require blog entries to exist in specific groups use a pipe separated list of group names.
    $bi_BlogGroups='JoesBlog|ZaksBlog|SusansBlog';

Also refer to site-wide modifications that can be made to BlogIt.

Setting up your Blog

Main Blog Summary Page

Your main page (in this example Blog.Main) is going to be a basic page list, which will include blog summaries, the part upto the "Read more..." link. By default you'll want to include all blog entries in the blog1 blog, of status Publish. For example, create a page Blog.Main:

(:notitle:)
(:includesection "#blog-summary-pagelist blogid=blog1 status=$[publish]":)

If you want to display Sticky entries before Published entries then add another pagelist:

(:notitle:)
(:includesection "#blog-summary-pagelist blogid=blog1 status=$[sticky]":)
(:includesection "#blog-summary-pagelist blogid=blog1 status=$[publish]":)

Blog SideBar

The BlogIt sidebar includes a admin control panel (visible to administrators), the list of recent articles, and comments, and the tag-list, ensure your Site.SideBar includes BlogIt-SideBar. Basically wrap the original sidebar in an if condition. (Don't forget the closing (:if:) at the end.)

(:if equal {$bi_BlogIt_Enabled} 1:)(:include Site.BlogIt-SideBar:)
(:else:)
<<original sidebar text>>
(:if:)

If you are using multiple blogs, then pass the blogid as a parameter (replacing MY_BLOG_ID):

(:if equal {$bi_BlogIt_Enabled} 1:)(:include Site.BlogIt-SideBar blogid=MY_BLOG_ID:)
(:else:)
<<original sidebar text>>
(:if:)

In order to view the control panel on the sidebar, users need to have 'sidebar' action assigned. Refer to security setup for more details.

Start using your Blog

Create New Blog Entries

Now you're ready to create a new blog entry -- simply click on the "New Entry" link in the sidebar. If you're not using the BlogIt sidebar, then simply visit the page Site.BlogIt-NewEntry. If you see a blank page, then make sure you have appropriate privileges.

Complete the blog entry form. Typically you will enter a Blog Title, Tags, select a Status, and then enter the blog entry text -- you usually don't need to touch the other fields.

Click to Enlarge

  • Blog Title: The name of the blog entry. The name will hyphenated, and use to name the pmwiki page (refer to the Pagename field), and will thus become part of the url. Usually you want this to be as descriptive of the blog-entry as possible.
  • Tags: One or more comma separated tags. These are the same as PmWiki Categories, and may be used to group entries by topics. The tags are shown to readers as links which when clicked list other similarly tagged blog entries. The tags are also shown in the sidebar tag list.
  • Status: Blog entries can be either Draft, Publish, or Sticky (additional statuses can be added if required). Statuses are usually used within pagelists to differentiate between groups of blog entries. Sticky entries are usually displayed on the front-page, before the Published entries.
    Draft entries are the only status where unique processing takes place. Draft entries will not appear in the sidebar Recent Entries list, and will not appear in tag lists. They will also not be accessible to non-authenticated users.
  • Comments: Defines whether readers can leave comments for this blog entry. The value selected here applies only to this entry, and can be over-ridden site wide with the $bi_CommentsEnabled setting.
    • Open: Allows readers to leave comments.
    • Read Only: Readers cannot leave new comments, but can read comments that have already been made.
    • None: Readers cannot leave new comments, and existing comments are not displayed. Note that existing comments still exist, and are not deleted, they just are not shown.
  • Blog Entry: This is the large unlabelled textarea. Use any PmWiki markups and text formatting.
    The [[#break]] anchor can be used to break longer blog entries into an introduction, and a 'body'. When the blog-summary pagelist is used (usually on the main page), blog-entries will be displayed up to the [[#break]] tag, where a "Read more..." link will be displayed. Readers can click the link to read the rest of the entry. You can change the tag used to break entries, or change the text displayed to readers when the break tag is used.
  • Pagename (Group.Name): Usually you'll leave this field as it is -- just don't enter a value here. This field is pre-populated with the default blog group. If you leave this field with only the blog group, the blog entry will be saved in a PmWiki page named by hyphenating the title field.
    If you want the page to be saved in a different PmWiki group, or you want the page to have a different name to the value in the Title field, then enter a value. Make sure the name you provide here is a valid PmWiki pagename (ie, no spaces), and doesn't already exist. BlogIt will return an error if you specify an invalid pagename.
  • Author: Defaults to the value you previosuly entered. You can enter any name you like here, no validation is performed.
  • Date: This field will be pre-populated with the current date and time. You can change this to any valid date/time combination. The default format for entering a date (which can be changed) is 15-03-2009 23:34.
    If you set a date/time which is in the future, the entry will not appear in pagelists until that date/time arrives. More information on this behavior is in the FAQ.

Comment Administration

Whenever you see a comment, and if you are logged in with the appropriate privileges, you will see a set of admin links, allowing you to either Approve/Unapprove, Delete, Edit, and Block a comment. Some actions require appropriate privileges.

  • Comment Approval: By default, if you have Captcha enabled, reader comments do not need to be reviewed and approved before being publicly visible. You can change this behavior, and manually approve comments before making them visible. If you are logged in with comment-approve or blogit-admin privileges, then your comments will automatically be approved.
    If you are manually approving comments, use the "Unapproved comments" link in the sidebar -- this link will also show a count of how many unapproved comments there are. (If you don't use the BlogIt sidebar, then add this to your blog url ?n=Site.BlogIt-Admin?action=blogitadmin&s=unapproved-comments&blogid=blog1.) The "Unapproved comments" page will show a list of all comments awaiting approval, for each blog-entries. Simply click the Approve, or Unapprove. As you approve comments they will be automatically removed from the list. Needs 'comment-approve' privilege.
  • Deleting Comments: When you click the Delete link on a comment you will be asked to confirm the delete. BlogIt uses PmWiki's delete mechanism, so if you do delete a comment in error, the deleted page still exists on the server (with a timestamp) and can be restored to the former page by the wiki administrator. Needs 'comment-edit' privilege.
  • Editing Comments: Comment editing allows you to use a form to edit any element of the comment, or manually change the comment status. Needs 'comment-edit' privilege.
  • Blocking Comments: You can view the commenters IP address, and then choose to add that IP address to the standard PmWiki blocklist page, usually SiteAdmin.Blocklist. When clicking the Block link, you will be presented with the IP address of the comenter. Either accept this, or change it, perhaps to include a '*' wildcard. Needs 'comment-approve' privilege.
    Note: You need to enable Blocklist? with $EnableBlocklist=1; and the SiteAdmin.Blocklist needs to exist, otherwise BlogIt will be unable to write to the page.

By default comments will automatically be approved if you have captcha enabled. You can change this behavior by setting $bi_DefaultCommentStatus.

Security

Most blogs are not public, so at the very least you probably want to lock things down, by adding edit and admin passwords to config.php:

$DefaultPasswords['admin'] = crypt('secret');
$DefaultPasswords['edit'] = crypt('secret');

BlogIt Roles and Actions

By default BlogIt defines a single 'role' with all 'actions' assigned to the role. Currently valid actions are:

  • 'comment-edit': Ability to edit all user comments, and to view Unapproved Comments.
  • 'comment-approve': Ability to approve comments, and view Unapproved Comments.
  • 'blog-new': Allows the user to create new blog-entries.
  • 'blog-edit': Permit editing of existing blog-entries, including changing the blog-status from Draft to Published.
  • 'sidebar': View the BlogIt sidebar, which provides quick access to Draft, Published, Sticky, Statistics, etc.
  • 'blogit-admin': Access to the blogit-admin page which displays drafts/published, etc.

Using Standard PmWiki Security (not using AuthUser)

By default anyone with Edit permissions is able to perform all actions. You can change this behavior by over-riding $bi_Auth. The array takes this format:

  • a single string with the name of the role. If you're not using AuthUser role names should be "edit" or "admin". If you are using AuthUser role names can be anything you like.
  • an array of actions.

By default the array is:

$bi_Auth = array(
   'edit'=>array('comment-edit', 'comment-approve', 'blog-edit', 'blog-new', 'sidebar', 'blogit-admin')
);

You might want to change that so only Admins can edit and approve comments:

$bi_Auth = array(
   'edit'=>array('blog-edit', 'blog-new', 'sidebar', 'blogit-admin'),
   'admin'=>array('comment-edit', 'comment-approve')
);
  • If you are not using AuthUser, then roles are heirarchical. So 'admin' will inherit 'edit' actions.
  • By default BlogIt requires edit permissions to be set on a page defined in $bi_AuthPage, initially to $bi_DefaultGroup.$DefaultName (usually Blog.Main). You can change this page to any page whith edit permissions set -- BlogIt simply uses this to determine that the user has Edit permissions, and does not change this page.

Using AuthUser

You can use AuthUser to provide fine grained access to the blog and it's features.

Here's an example where we use two BlogIt roles, one for blogs and one for comments. We then setup two users, 'step' who can create/edit blog-entries, and 'daveg' who can approve comments.

# [1] Define BlogIt roles, and associated actions
# Actions: 'comment-edit', 'comment-approve', 'blog-edit', 'blog-new', 'sidebar', 'blogit-admin'
$bi_Auth = array(
	'blogs'=>array('comment-edit','blog-edit', 'blog-new', 'sidebar','blogit-admin'),
	'comments'=>array('comment-approve', 'sidebar','blogit-admin')
);

# [2] Define users passwords
$AuthUser['daveg'] = crypt('daveg');  #set daveg password
$AuthUser['step'] = crypt('step');  #set daveg password

# [3] Add users to the roles
$AuthUser['@blogs'] = array('step');
$AuthUser['@comments'] = array('daveg');

# [4] Assign roles to security groups
$DefaultPasswords['blogs'] = array('@blogs');
$DefaultPasswords['comments'] = array('@comments');

# [5] Assign roles to pmwiki actions
$DefaultPasswords['edit'] = array('@blogs', '@comments');

include_once("$FarmD/scripts/authuser.php");

Alternately you can simply store passwords [2] and users/role assignments [3] in Site.AuthUser, in the normal way.

Internationalization

If you create a new translation, please post it for others to use!

Language Translations

BlogIt utilizes PmWikis built in internationalization mechanism. All text strings are stored in Site.XLPage-BlogIt.

  1. Either create a new language translation page, or use an existing one. To create a new page, copy the content of Site.XLPage-BlogIt to a new page, ie, Site.XLPage-BlogIt-LANGUAGE, and enter the translations within the empty quotes. For example, replace the empty quotes below:
    'more' => ''
    
    With the language translation:
    'more' => 'plus'
    
  2. Load the page in config.php:
    XLPage('ABBR','Site.XLPage-BlogIt-LANGUAGE');
    
    

You can also use this method to rename any of the labels that BlogIt uses. So if you prefer to have the "more" link in the sidebar read "archive" just create a new XLPage and load it in config.php, using the preferred term rather than a 'true' translation. For example:

English XLPage:           'more' => 'archive'
Other Language XLPage:    'more' => 'more-translated'

Changing Date Display and Entry Formats

These date formats are defined by BlogIt. Note that a skin may define additional formats, so check in Site.XLPage-skinname.

  • long date: %B %d, %Y, at %I:%M %p
  • short date: %B %d, %Y
  • date entry: %d-%m-%Y %H:%M

You typically want to change date formats when you use PmWiki in a non-English language. BlogIt date formats are stored in Site.XLPage-BlogIt -- so simply make a copy of that page, and load it as you would when adding internationalization support.

Alternately, if you want to change the date formats and not make any other language alterations, add this to config.php, using the original format in the list above as the string used in the array. In this case the 'long-date' is being redefined to %d %B, %y, at or around %H:%M:

$XLLangs[]='blogit';
$XL['blogit']['%B %d, %Y, at %I:%M %p'] = '%d %B, %y, at or around %H:%M';

Changing the Character Set

BlogIt automatically uses UTF-8 character set for page names. You can change this behavior in the using the basic PmWiki configuration, by changing $MakePageNamePatterns, for example Cookbook.ISO8859PageNameConversionPatterns. For example to use ISO-8859:

# additonal character conversion patterns for ISO 8859-1 character set
SDV($PageNameChars, '-[:alnum:]');
SDV($MakePageNamePatterns, array(
    "/'/" => '',
    "/[^$PageNameChars]+/" => ' ',
    '/((^|[^-\\w])\\w)/e' => "strtoupper('$1')",
    '/ /' => ''
));
# additonal character conversion patterns for ISO 8859-1 character set
SDV($ISO88591MakePageNamePatterns, array(
	'/Á/' => 'A',	'/Â/' => 'A',	'/Ã/' => 'A',	'/Ä/' => 'Ae',	'/Å/' => 'Ao',	'/Æ/' => 'Ae',	'/Ç/' => 'C',
	'/È/' => 'E',	'/É/' => 'E',	'/Ê/' => 'E',	'/Ë/' => 'E',	'/Ì/' => 'I',	'/Í/' => 'I',	'/Î/' => 'I',
	'/Ï/' => 'I',	'/Ð/' => 'D',	'/Ñ/' => 'N',	'/Ú/' => 'U',	'/Ó/' => 'O',	'/Ô/' => 'O',	'/Õ/' => 'O',	
	'/Ö/' => 'Oe',	'/Ø/' => 'Oe',	'/Ù/' => 'U',	'/Ú/' => 'U',	'/Û/' => 'U',	'/Ü/' => 'Ue',	'/Ý/' => 'Y',	
	'/Þ/' => 'Th',	'/ß/' => 'ss',	'/à/' => 'a',	'/á/' => 'a',	'/â/' => 'a',	'/ã/' => 'a',	'/ä/' => 'ae',
	'/å/' => 'ao',	'/æ/' => 'ae',	'/ç/' => 'c',	'/è/' => 'e',	'/é/' => 'e',	'/ê/' => 'e',	'/ë/' => 'e',	
	'/ì/' => 'i',	'/í/' => 'i',	'/î/' => 'i',	'/ï/' => 'i',	'/ð/' => 'd',	'/ñ/' => 'n',	'/ò/' => 'o',	
	'/ó/' => 'o',	'/ô/' => 'o',	'/õ/' => 'o',	'/ö/' => 'oe',	'/ø/' => 'oe',	'/ù/' => 'u',	'/ú/' => 'u',	
	'/û/' => 'u',	'/ü/' => 'ue',	'/ý/' => 'y',	'/þ/' => 'th',	'/ÿ/' => 'y'
));
# join to standard patterns
$MakePageNamePatterns = array_merge($ISO88591MakePageNamePatterns, $MakePageNamePatterns);

Skin Support

Some skins provide additional support for BlogIt, allowing page elements to be repositioned and syled specifically for that skin. In cases where the skin does not provide this built-in support you have a few options for improving the standard appearance. The standard PmWiki skin is an example of a skin that will work with BlogIt, but whose appearance can be improved by using an additional stylesheet.

Skin Stylesheet Setup

Each part of the page that BlogIt generates is identified by a CSS ID or class. You can use these identifiers to alter the appearance of BlogIt page elements. This is done with stylesheets.

Listed are some CSS styles for popular skins that don't have built-in support for BlogIt. You can load multiple stylesheets if needed, or load your own.

  1. Save the stylesheet in a publicly accessible directory, usually pmwiki\pub\css\.
  2. Add this to config.php, replacing 'blogit-pmwiki.css' with the name of the skin file you saved. (Note, that only the first line is specific to BlogIt -- the other lines are what PmWiki would normally set as default.)
    $PageCSSListFmt=array(
      'pub/css/blogit-pmwiki.css' => '$PubDirUrl/css/blogit-pmwiki.css',  #Load BlogIt PmWiki css file 
      'pub/css/local.css' => '$PubDirUrl/css/local.css',
      'pub/css/local.css' => '$PubDirUrl/css/local.css',
      'pub/css/{$Group}.css' => '$PubDirUrl/css/{$Group}.css',
      'pub/css/{$FullName}.css' => '$PubDirUrl/css/{$FullName}.css');
    
    

Skin Stylesheets

Listed below are some CSS stylesheets for skins that don't natively support BlogIt. These skins can still be used with BlogIt, with or without the stylesheets -- the stylesheets simply improve the styling for the page elements that BlogIt adds.

If the skin you use is not listed below, try using the PmWiki stylesheet -- it provides some basic styling to BlogIt elements that should work on most skins.

Feel free to add your own stylesheets for your favorite skins.

  • PmWikiΔ: Provides basic styling for the standard PmWiki skin.
  • TriadΔ: Provides basic styling for the popular Triad skin. Also load the PmWiki stylesheet for more complete styling. Note that this stylesheet is setup for Triad using the 'choc' color theme. If you use another color theme, then update the two colors for the classes 'h2 a' and '.blogit-meta-data-footer'.

Validate XHTML Strict

In order to ensure strich XHTML validation with skins which are written to that specification add this to config.php:

## For strict validation
SDV($InputTags['end'][':html'], '</fieldset></form>');
SDVA($InputTags['pmform'][':html'], "<form action='{\$PageUrl}' \$InputFormArgs><fieldset><input type='hidden' name='n' value='{\$FullName}' /><input type='hidden' name='action' value='pmform' />");

Adding More Features to your Blog

BlogIt provides basic blog support, but relies on other cookbooks to add functionality. Below are some cookbooks that work well with BlogIt, and some suggested settings. Of course, there are always options -- you don't have to use these cookbooks, others will likely work with no issues.

Stop Comment Spam

Comment captcha will only work if you assign Edit and Admin passwords.

Three days after I posted the link to the demo site on the PmWiki mailing list I was getting comment spam. Stop it dead, with Captcha. Add this before including blogit.php.

$EnableCaptchaImage=1;
if (!CondAuth($pagename,'edit')) $EnablePostCaptchaRequired = 1;
include_once("$FarmD/cookbook/captcha.php");

Captcha will now be active for comments. Captcha is automatically deactivated when creating or editing blog entries, since you need to be logged in under the Edit or Admin password in order to edit.

If you don't see the captcha enabled for comments, make sure you have assigned edit and admin passwords on your wiki. If you don't assign passwords, then everyone has Edit and Admin access, which causes BlogIt to disable the captcha. The implication of this is that you can't currently use BlogIt in a completely open wiki (no edit or admin passwords), and also enable Captcha -- if there is strong demand for this type of blog then let me know.

Improved Edit Toolbar Icons

Use EditToolbar for an improved toolbar while you edit. You need to enable buttons BEFORE you include blogit.php, otherwise the buttons will not be displayed correctly.

$EnableGUIButtons = 1;
include_once("$FarmD/cookbook/edittoolbar.php");

Page Counters

Note: Full integration with TotalCounter is not currently implemented, as TotalCounter does not display page counts correctly within pagelists. BlogIt will display page counts set by cookbooks using the {$PageCount} variable, like TotalCounter.

include_once("$FarmD/cookbook/totalcounter.php");

Show YouTube and other videos

Use flash.php.

include_once("$FarmD/cookbook/flash.php");

Now include links to YouTube, and other flash videos by:

(:flash FULL_LINK_TO_VIDEO width=400 height=312:)

Google Sitemaps

One way to make sure your site is found by search engines is to submit a sitemap to the search engine. Use Google Sitemaps. In order to prevent search engines seeing pages they don't have access to, include some additional search patterns to exclude SiteAdmin, and the comment group.

if ($action=='sitemap'){
   $EnablePageListProtect = 1;
   $SitemapSearchPatterns[] = '!^SiteAdmin\.!';
   $SitemapSearchPatterns[] = '!^Comments\.!';
   include_once("$FarmD/cookbook/sitemap.php");
}

Page Conversion (to BlogIt, and away from BlogIt)

BlogIt uses Page Text Variables to store blog entry attributes. BlogIt pages look like regular PmWiki pages when viewed with BlogIt disabled -- because they are regular PmWiki pages. If you do a 'normal' PmWiki edit on a blog entry you'll see the variables BlogIt uses.

In order to either add or remove the attributes, simply use the converter utility. The utility can only be run by an Admin. All actions are controlled using URL parameters. Available parameters are:

  • action: blogitupgrade -- initiates the upgrade/conversion utility.
  • pattern: If this is not specified, then the upgrade will operate on the current page only. Multiple comma separated patterns can be provided. The pattern follows a regular expression format. By default the pattern is inclusive, and will match partial names, so 'Blog\.Page1' will also match 'Blog.Page12'; use a '$' at the end of each pattern to ensure a direct match 'Blog\.Page1$'. (Note: Even if you are using clean URLs, specify page names with a 'dot' separator.) The pattern will automatically include/exclude patterns specified by $SearchPatterns['default']. So if you want to exclude Site/PmWiki group pages, either setup your $SearchPatterns['default'] or specify the exclusion in the pattern.
    • Group\.*
    • Group\.Page
  • writetofile (true|false): only writes to the PmWiki file if this is "true" -- otherwise outputs results to browser. So leave this parameter off and verify output in the browser, before updating your PmWiki files.
  • mode (upgrade|convert|revert): If not specified, then BlogIt will attempt an upgrade. If you want to convert a vanilla PmWiki page into a BlogIt entry, then use the "convert". If you want to remove the PTV attributes from the page then use "revert".
  • blogid: Defaults to "blog1". Only use this if you are running a mutliple blogs from within the same wiki.

Conversion Process

This process will add PTV values to the PmWiki page. When you run the utility leave out the writetofile parameter until you've checked the results in the browser.

  1. Make a backup of wiki.d. This process has been rigorously tested -- but caution should prevail.
  2. Append ?action=blogitupgrade&pattern=Blog\. to your URL (for instance the homepage). This step makes no changes -- it outputs all changes that will be made. The pattern 'Blog\.' will process all pages in the Blog group. If you have a huge number of pages (more than a few hundred for instance) you might want to use a different pattern. Verify that the correct pages are being converted, and that things look right.
  3. Append ?action=blogitupgrade&mode=convert&pattern=Blog\.&writetofile=true to your URL (for instance the homepage). This step will write the changes to all matched pages, updating to the new format.

When you run without the writetofile parameter you should see something like:

Main.Main
[[#blogit_pmmarkup]](:title 12341:)[[#blogit_pmmarkupend]]
(:blogid:blog1:)
(:entrytype:blog:)
(:entrydate:1239246060:)
(:entryauthor:DaveG:)
(:entrytitle:12341:)
(:entrystatus:draft:)
(:entrycomments:open:)
(:entrytags::)
[[#blogit_entrybody]]2131[[#blogit_entrybodyend]]

Pattern Samples

Converting a Single Page

Convert the page "Blog.Main":

?action=blogitupgrade&mode=convert&pattern=Blog\.Main$

Converting All Pages in a Group

Convert all blog entries in the "Blog" group:

?action=blogitupgrade&mode=convert&pattern=Blog\.

Converting a number of pages

In this case we match all entries in groups Blog, and Main, the page MyGroup.MyPage, and all pages in the group MyGroup starting with 'A'. Patterns are inclusive by default, which is why the final pattern matches all pages starting with 'A'. Also note that the dot delimiter is prefixed with a '\' -- otherwise it means 'any character'.

?action=blogitupgrade&mode=convert&pattern=Blog\.,Main\.,MyGroup\.MyPage,MyGroup\.A

Use a '$' at the end of each pattern to ensure a direct match.

?action=blogitupgrade&mode=convert&pattern=Blog\.,Main\.,MyGroup\.MyPage$,MyGroup\.A$

Converting all pages

You can convert all pages at once, using the '.' wildcard. Use this with extreme caution, as it will convert all PmWiki documentation pages, and possibly other system related pages:

?action=blogitupgrade&mode=convert&pattern=.

Converting from BlogIt format to normal PmWiki pages

This function removes the PTV fields added by BlogIt, leaving basic PmWiki pages. You can do the same thing manually, by using the normal PmWiki 'edit' function, and removing the PTV fields.

?action=blogitupgrade&mode=revert

If everything looks okay, then commit the changes:

?action=blogitupgrade&mode=revert&writetopage=true

Advanced Changes to BlogIt

The following setting are also available, and can be made in a config file:

  • $bi_DefaultGroup (default 'Blog'): Pre-populates the Pagename field; blogs can exist in *any* group, not simply the default defined here.
  • $bi_CommentGroup (default 'Comments'): Default group where comments are stored.
  • $bi_DefaultCommentStatus (default 'true' if captcha enabled): Sets the default approved status for comments. Determines whether an admin need to approve each comment before it is displayed.
  • $bi_CommentsEnabled (default 'true'): Global setting to enable or disable comments. If comments are disabled, no new comments can be entered.
  • $bi_BlogGroups (default $bi_DefaultGroup): Pipe separated list of Blog groups. This is purely to speed up pagelists. Defining this list does not mean all pages in the group are 'blog-pages', but it does mean that blog pages will only be searched for in this group. Define as an empty string to search all groups for blog-entries.
  • $CategoryGroup (default 'Tags'): Group to be used for blog tags. Tag pages are automatically created in this group as tags are used within blogs.
  • $bi_AuthorGroup (default 'Profiles'): The group to be used for blog and comment author profiles, if used.
  • $bi_EntriesPerPage (default 15): Restrict the number of entries per page (default is 15). You can also set this within the pagelist itself if you want to over-ride the global setting.
  • $bi_LinkToCommentSite ('true'): Users may enter a "Website" when leaving a comment. This setting determine whether or not to display the "Website" as a link. Even when displayed as a link it will have the "nofollow" attribute.
  • $bi_BlogList (default array('blog1')): Used if you want to manage more than one blog on a single PmWiki installation. Adding additional blogs will automatically create a select list on the blog entry form so you can choose which blog the post belongs to. Ensure 'blog1' key remains.
  • bi_Paths: BlogIt automatically loads three cookbooks as needed. This array defines the paths to those cookbooks. Default:

array('pmform'=>"$FarmD/cookbook/pmform.php", 'guiedit'=>"$FarmD/scripts/guiedit.php", 'convert'=>"$FarmD/cookbook/blogit/blogit_upgrade.php")

Changing Blog Status

You can add new status values to the pull-down list available on the new entry form. You might do this if you want additional groups of blog-entries.

$bi_StatusType['new status']='new status';

FAQ

Also refer to the Talk pages -- someone may have had a similar problem or question.

Changing Tag Used for Breaking Entry

You can change both the tag used to determine the end of the entry introduction (by default [[#break]], and also the text used to display the link to the full entry (by default Read more...). As with date formats you can either change the entries in the XLPage, or make a change in config.php:

$XLLangs[]='blogit';
$XL['blogit']['break']='split';
$XL['blogit']['Read more...']='Continue reading...';

Note: If you change the break tag, then entries using the old break tag will no longer break. You'll need to manually update entries which use the older break tag.

How to hide the standard Action menu

You can hide the action menu (containing View, Edit, History, Backlinks) on an individual page by adding this markup to the page:

(:noaction:)

Or for the whole wiki with:

SetTmplDisplay('PageActionFmt',0);

The notitle directive does not remove title from blog summary list

This is really down to how the summary list was designed to work -- without the title there would be no deliniation between blog entries. However, you can override this functionality by overriding the blog summary pagelist, or creating a new pagelist. To override the default pagelist, which is in Site.BlogIt-CoreTemplate:

  1. Create a PmWiki page called Site.BlogIt-SkinTemplate-SKINNAME, or edit the page if it already exists -- replace the word SKINNAME with the name of the skin you are using.
  2. The exact markup you see will depend on the skin you are using. Use this sample as a template for creating the list as you want to see it. For instance remove the heading line (2nd line) to remove the page title:
    !!! #common-blog-head
    Parameters: title, listformat (show header or not), entrydate, entrytags, fullname, entryauthor, showcount
    [==[@==]
    (:if false:)[[#common-blog-head]](:if:)
    (:if equal "{$$listformat}" "true":)!! [[{$$fullname} | {$$title}]](:if:)
    (:div9999 class="blogit-meta-data-head":)
    (:blogit-skin author pre_text='!!!!!$[By] ' post_text=', $[on] ':){$$entryauthor}(:blogit-skinend:)\
    %blogit-date%(:blogit-skin date fmt='long':){$$entrydate}(:blogit-skinend:)%%(:if:) \
    (:blogit-skin edit pre_text='%blogit-edit-link%%item accesskey="$[ak_edit]"%' post_text='%%' page='{$$fullname}':)$[edit](:blogit-skinend:)
    (:div9999end:)
    [[#common-blog-headend]]
    [====]
    

@]

How can I create a list of only the last (newest) n entries?

Simply add count=n (replace the 'n' with a number) to the includesection statement or for a global setting set $bi_EntriesPerPage in config.php.

bi_EntriesPerPage = 10; #default is 15

How to Display Future Dated Entries?

BlogIt will not display entries which are dated beyond the current date. This way you can future date an entry, and it will automatically be displayed once that date is reached, if it is in "Publish" status.

If you want to always display future dated entries:

$bi_DisplayFuture = 'false';

Does BlogIt use cookies?

If you login as a user with BlogIt privs, BlogIt will use cookies to keep track of the page history trail (last two pages). It does this to make the Admin workflow smoother. So when you cancel a blog edit, or when you approve a comment, BlogIt will return to the page you were on previously. The cookie is only maintained for the current session, and is removed when you close the browser.

Cookies are not used for blog readers.

Admin is Redirected to Incorrect Page [#faq-incorrect-redirect]]

If you are consistently being redirected to the same wrong page after performing an Admin function (comment edit, comment delete, comment approve, cancel from a blog edit, etc), and you were using BlogIt prior to version 1.2.0 delete all cookies associated with blogit:

  • Site: Should be the domain name of your site.
  • Cookie Name: blogit-back-1 and blogit-back-2

If you see multiple cookies with the same cookie name (blogit-back-1 and blogit-back-2), delete them all.

Change the default BlogIt styling

You can change the styling of BlogIt elements by using a stylesheet. Some skins come packaged with styling for BlogIt-specific elements. For skins that don't include specific styling for BlogIt you the PmWiki BlogIt stylesheet might work, or might be a good basis to create a new stylesheet for your skin.

Prevent Formatting in Comment when displayed in sidebar

BlogIt displays the first sentence (or until the first newline) of each comment in the Sidebar. Sometimes user use basic PmWiki formatting within comment, and this can adversely affect the look of the sidebar. For instance, if the comment text starts with %red% then the comment in the sidebar will be red. You have a couple of options in these cases:

  1. Edit comments either removing the offending formatting, or add a summary first sentence with no formatting.
  2. Use a recipe like MarkupToUnstyled to strip sidebar comments of formatting, and then tell BlogIt to use the function with $bi_UnstyleFn:
include_once("$FarmD/cookbook/markuptounstyled.php");
$bi_UnstyleFn = 'MarkupToUnstyled';
  1. Define a style to override the most common comment sidebar styling:
    $HTMLStylesFmt['bi-pmwiki'] .= '.blogit-comment-summary-list li span {font-size: 100% !important;} ';
    
  2. Define a style to override the most common comment sidebar styling, and then apply the style to the offending sentence in the comment, Thus, when the first line of a comment needs sanitizing, the reviewer can simply surround the offending sentence with the new class %sidebaronly%sanitized title%%.
    $HTMLStylesFmt['bi-pmwiki'] .= '.sidebaronly { display:none; } #sidebar .sidebaronly { display:inline; }';
    

Problems with Passwords

BlogIt needs to be able to access text within pages -- that means it needs to be able to access pages. Thus BlogIt has to be included:

  • AFTER passwords are defined in config.php
  • AFTER the inclusion of the authuser script (if you're using it)

Automatically Approve all Comments

By default comments DO NOT need to be approved by an admin. If you have a captcha enabled, then that's usually enough to stop spam. However, if you need a level of admin approval set this in config.php:

$bi_DefaultCommentStatus = 'false';

Unapproved comments don't show in control panel

If you override $bi_DefaultCommentStatus make sure you provide a string value, not a 'boolean' value:

$bi_DefaultCommentStatus='false';

The browser title bar title shows the title from a blog-entry

You have manually included a (:title TBD:) markup in the body of one of your blog entries. Currently PmWiki gives precedence to titles that occur last in a page. Since the blog list page includes the first part of the blog entry, which includes the title markup, it overrides any prior title markups on the blog list page. You can work around this by setting a (:title TBD:) at the very bottom of the blog list page, after all the pagelists. Alternately refer to the one line fix on PITS 00779.

No entries listed in Recent Entries section

If you see no entries listed under the sidebar "Recent Entries" heading, and you do have entries that you would expect to see listed, ensure you have set the following in config.php. More info is on the Talk Page:

 
$EnableRelativePageVars = 1; 

Setting up an RSS feed

Trevor has provided a detailed tutorial describing one way to setup an RSS feed on top of BlogIt.

Using the Drafts and BlogIt

If you are logged in as an Edit user, and have enabled both Drafts and BlogIt, and try to perform an ?action=edit on a non-BlogIt page, then the Publish button will not be enabled. In this scenario you will need to ensure that you include the Drafts recipe from config.php, rather than relying on PmWiki to automatically include Drafts.

$EnableDrafts=1;
include_once("$FarmD/scripts/draft.php");
include_once("$FarmD/cookbook/blogit/blogit.php");

Some background: Drafts are enabled in PmWiki using $EnableDrafts=1, which provides a mechanism for saving pages a separate draft pages, with a "-Draft" suffix, and then later publishing the draft to the final page, basically changing the page name removing the "-Draft" suffix. This workflow doesn't really align with the way in which typical blogs operate, and so BlogIt implements it's own draft mechanism. In addition even if you were to enable Drafts, BlogIt doesn't use the normal PmWiki edit action, and so you would not see the Publish/Draft buttons.

Roadmap

The roadmap outlines the likely areas of focus for future releases of BlogIt, and provides guidance on how known issues will be addressed.

  1. Stability: Remove known bugs. Ensure coding approaches leverage the PmWiki framework appropriately. Security shake-down.
  2. Functionality Alignment: Verify co-existance with existing blog-related recipes. Bring the blog features up to par with traditional blogging platforms.
  3. User Interface: Create templates for existing skins, ajax ui, control panel.
  4. Scale Up: Ensure performance scales to blogs with thousands of pages, and comments.
  5. Importing: Provide a means of importing pages from existing systems (Blogger, WordPress, etc).

Known Issues

  • List is grouped by issue type, and within that group is in approximate level of urgency, so items near the top of each issue type are likely to get implemented first.
  • Green highlighted items will be worked on for the next release. Green items with strike through have been implemented, but are not yet released.
  • Items in parenthesis "(bug)" are low priority, and are unlikely to be addressed.

Bugs

  • bug: Setup fails when called from a local/group.php. (Reported by SteP)
  • bug: Dash in blog group name causes problems when un-approving and deleting comments. (Reported by SteP) (Make separator/pagenaming scheme used in pagename user-configurable.)
  • (bug): Ajax message box is not displayed in IE6.
  • (bug): Unsaved data warning is inconsistent across browsers: Opera and IE6 do not implement the event onbeforeunload; Chrome prompts even if Save button is pressed.

New

  • new: Ajax comment submit.
  • new: Show 'preview' of comment before post. (Requested by Luigi)
  • new: Provide a preview mechanism for blog entries. ($_REQUEST['preview'] = 1;)
  • NEW: Control panel/dashboard for blog settings.
  • new: Provide support for displaying externally hosted gravatar based on name entered for comments. (Suggested by Luigi)
  • new: Ajax enable captcha failure. (Perhaps making the page reload is better to slow down spammers?)
  • new: Provide support for displaying twitter link based on name entered for comments. http://img.tweetimag.es/i/kirpi(approve links) (Suggested by Luigi)
  • new: Provide a means of approving comment url's when used with UrlApprovals (Ajaxify). (Requested by Step)
  • new: Create a pagelist which shows other pages with the same tags as current page, grouped=by tag.
  • new: List comments by person. (Provide a pagelist that can be manually included as part of Profile group-header.)
  • new: Add a mechanism to hide PmWiki edit link on blog entries (prevent confusion as to which edit link to use).
    • At times plain wiki edit (?action=edit) is useful also on blog pages. While preventing confusion is essential, straight hiding the link would be deceiving to many people, perhaps. -- Luigi
  • new: Add a mechanism to incorporate EditTemplates, to prepopulate the blog entry. (Requested by Luigi)
  • new: BlogIt-SideBar tags list should only show tags for a specific blog (not all blogs). (Need to add PTV to the auto-generated tag page, containing the blogid; this ptv can then be used on pagelists.)
  • (new): Store intro-text (upto [[#break]] tag, as (:Summary :...:). Might make processing faster? Will provide functionality if BlogIt is not being used.
  • (new): Import from Google Blogger.

Changes

  • chg: Rename url parameters to "bi_" to prevent possible conflicts (include bi_upgrade parameters).
  • CHG: Rename blog and comment fields, prefix with "blogit_" identifier, to prevent conflicts with other recipes.
  • chg: Ensure comment names are unique. (MakeSerialNumber())
  • CHG: Simplify BlogIt security. There is not a clear deliniation between various actions. Basically there are too many actions. (ie, remove blogit-admin and sidebar and simply check for other actions; combine blog edit/new; combine comment-approve/edit.)

Documentation

  • doc: Add advanced skinning documentation, including templates and template ordering. and a list of vanilla stylesheet with all classes and ids that BlogIt-CoreTemplate uses. (Requested by SteP)
  • doc: Comment page naming scheme.
  • doc: More add-on features (RSS, Sitemap).

Issues that need additional verification

If you are able to repeat any of these issues, please let me know how you did it!

  • new: Verify support with Cookbook/ListCategories (may work -- not yet tested).
  • new: Verify support with Cookbook/AutoSave (may work -- not yet tested).
  • new: Verify support with Cookbook/XMLRPC (may work -- not yet tested).

Change Log

The most recent changes are listed below. A full archive can be found in the BlogIt release history.

1.4.0 (14-Mar-2010)

Contributors: DaveG, Luigi
NOTE: If you are upgrading from a release prior to 1.2.0 make sure you read the 1.2.0 upgrade notes.

Release Summary

  • Many Admin functions are now 'ajax' based, and are much quicker, being performed without reloading the page (ajax). (Currently comment un/approve, comment delete, comment block, entry delete, comment and blog entry form validation.)
  • Added link to block commenter IP address if BlockList is being used ($EnableBlocklist).
  • Field validation is now done in the browser, so error messages are seen immediately.

Release Details

  • new: Perform client side error checking for comments, providing immediate feedback to user. (Requested by Luigi)
  • new: Link to delete blog entries, rather than going through PmWiki edit link. (Requested by valeh?)
  • new: Add option to add commenter IP to Site.BlockList.
  • new: Display IP address on user comments, possibly in same way as PmWiki History page, on hover over user name. (Requested by Luigi)
  • new: Add a confirmation on comment delete.
  • new: Ajax comment approve/unapprove.
  • new: Ajax comment delete.
  • new: When posting comments, errors and messages are not immediately visible, the page sits at the top and do not jump back to the form. (Reported by Luigi)
  • new: Provide message feedback on comment approval. (Make bi_Redirect a pmwiki action? Problem is due to loosing $MessageFmt during redirect.)
  • new: Add client side date validation check for blog entry.
  • new: Added class "blogit-blog-form" to blog entry form, and "blogit-comment-form" to comment form.
  • new: Display warning if there are unsaved changes on the blog entry page, when navigating away from page with changed content.
  • new: There should be some "filter" on blogitupgrade to not change special pages like "RecentChanges" and the like. (Possibly restrict to $SearchPatterns.) (Suggested by Luigi)
  • bug: Trailing URL's in comments have %% appended. Solution is to use bracket [[http:...]] markup. (Reported by Luigi)
  • bug: Date on blog-grid (for Published, Draft, Sticky) is displayed incorrectly '07-02-2010( 20:29)?'.
  • bug: Do not display comment count if comments are off for the blog-entry or globally (occurs on default PmWiki skin, and DropShadow, Skittlish). (Reported by Luigi)
  • bug: If $Skin is set after BlogIt include then skin template is not loaded. (Reported by Luigi)
  • bug: Approve/unapprove doesn't add to the revision history, it changes the prior revision history.
  • bug: Comments and entries with newlines are stored in multiple lines in page["text"], rather than on a single line.
  • bug: Entries with no author have a non-bold entry date tagline on PmWiki skin.
  • bug: On blog entry, if date is null, then error is thrown. Should default to current date/time.
  • bug: If using $bi_EnablePostDirectives, then don't reset $PmFormPostPatterns, only remove (:..:...:) pattern.
  • bug: Editing a 2nd comment causes redirect fail. First comment edit redirect works; 2nd comment edit redirect fails.
  • bug: notitle markup is not obeyed in blog summary list. (Reported by Luigi) notitle operates correctly on the single entry view, which is how notitle should work. Refer to the FAQ in order to remove it from the blog summary list.
  • chg: On comment submit if you omit the email you get *three* error messages. (Reported by Luigi)
  • chg: Email is only validated client side, not on server.
  • chg: Turn off captcha if user has any form of bi_Auth ($EnablePostCaptchaRequired)
  • chg: Added new XL strings:
    ### ajax messages
      'Yes' => '',
      'No' => '',
      'Are you sure you want to delete?' => '',
      'Unable to perform delete operation.' => '',
      'Delete successful.' => '',
      'approve comment' => '',
      'unapprove comment' => '',
      'Unable to ' => '',
      'Unable to block IP address.' => '',
      'Blocked IP address: ' => '',
      'IP address is already being blocked: ' => '',
      'Unable to determine IP address.' => ''
      'Commenter IP: ' => '',
      'Enter the IP to block:' => '',
      'Submit' => '',
      'Cancel' => '',
      'Either enter a Blog Title or a Pagename' => '',
      'You have unsaved changes.' => '',
    
    ### validity messages
      'This field is required.' => '',
      'This field must be formatted as a date.' => '',
      'This field must be formatted as an email.' => '',
      'This field must be formatted as a URL.' => ''
    

1.3.2 (16-Feb-2010)

Contributors: DaveG, swissc4
NOTE: If you are upgrading from a release prior to 1.2.0 make sure you read the 1.2.0 upgrade notes.

Release Summary

  • Corrected bug which prevents posts or comments, causing error: "An author name is required. Unable to save page".

Release Details

  • bug: When posting entries or comments, using standard security (not AuthUser), and with $EnablePostAuthorRequired=1, the error "An author name is required. Unable to save page" is displayed. (Reported by swissc4)

1.3.1 (16-Feb-2010)

Contributors: DaveG, Luigi
NOTE: If you are upgrading from a release prior to 1.2.0 make sure you read the 1.2.0 upgrade notes.

Release Summary

  • Corrected bug when running blogitconvert with default PmWiki security.

Release Details

  • bug: Error when running blogitupgrade with default security (not AuthUser). "Fatal error: Function name must be a string in /cookbook/blogit/blogit.php on line 472". (Reported by Luigi)
  • bug: Prevent include sections becoming part of page targets list.
  • chg: Remove use of depreciated split() function.
  • chg: Support use of time formats in (:blogit-skin date markup.

1.3.0 (30-Jan-2010)

Contributors: DaveG, SteP
NOTE: If you are upgrading from a release prior to 1.2.0 make sure you read the 1.2.0 upgrade notes.

Release Summary

  • Comment editing now uses the comment entry form rather than the default PmWiki edit form.
  • Comments will only auto approve if captcha is active, or if you explicitly set $bi_DefaultCommentStatus to true.
  • If you amended SkinTemplate, or set values for these variables in config.php you'll need to update: Changed {$bi_AdminPage}->{$bi_Pages_ADMIN}, {$bi_NewEntryPage}->{$bi_Pages_NEW_ENTRY}, {$bi_BlogList}->{$bi_Pages_BLOG_LIST}, {$bi_AuthPage}->{$bi_Pages_AUTH}
  • If you've added XL language translations these values were added: 'Comment Approved?', 'true', 'false'

Release Details

  • new: Improve comment editing with comment edit form. (Requested by SteP)
  • new: If captcha is enabled, or use has comment privs, than auto-approve comments. Otherwise default to manual approval.
  • new: Add date to Tag list, same as seen on BlogList.
  • chg: Site.BlogList should list published AND sticky entries (Requested by SteP)
  • chg: Sidebar Recently Written 'more...' link loads Site.BlogList, which is hardcoded for blog1. Site.BlogList now includes a blogid parameter for easier use in multi-blog environments.
  • chg: $bi_MakePageNamePatterns should not contain hardcoded hyphens. Use $bi_TitleSeparator.
  • chg: Put blogit pages in array. (Now stored in $bi_Pages: $bi_AdminPage, $bi_NewEntryPage, $bi_BlogList, $bi_AuthPage)
  • chg: Cookie history should be an array. (Now $bi_History)
  • chg: Created $bi_Pages, $bi_Forms, bi_History, added function bi_setFmtPVA back.
  • chg: Made assignment of $PmForm['blogit-entry'] and $PmForm['blogit-comments'] SDV.
  • chg: Updated cookie history mechanism (works on comment cancel, and in more situations on blog edit)
  • chg: Move form control buttons (Save, Cancel, Post) out of #comment-form and #blog-form (under skin control) and into #(comment|blog)-form-control (under CoreTemplate control).
  • chg: blogit_upgrade uses the first set of rules if no specific version is specified. Means we no longer need to update the $bi_ConvertRules version array key for each new release of BlogIt.
  • bug: Title with periods causes "Pagename is required." error. (Work-around is to manually enter the Pagename, excluding periods.)
  • bug: Changing the date entry format to '%d/%m/%Y %H:%M' causes day and month fields to be switched. (Reported by SteP)
  • bug: $action inadvertently overridden and set to blogitupgrade. (Reported by SteP)
  • bug: Some sections in CoreTemplate were not correctly closed.
  • bug: Only include blogit_upgrade.php if use has 'blogit-admin' permissions.
  • bug: Full page is stored in internal page history at every Save, not just delta changes. Update: This is the default processing for PmWiki with PTV fields.
  • new: Allow override of BlogIt title naming mechanism. (Suggested by SteP) Handled via PmWiki edit hooks.
User notes: If you use, used or reviewed this recipe, you can add your name. The following format is recognized:
* (+) Optional positive comment. Name, date
* (-) Optional negative comment. Name, date

These statistics appear in the Cookbook listings and will help newcomers browsing through the wiki.

Edit - History - Print - Recent Changes - Search
Page last modified on March 14, 2010, at 04:06 PM