Minor Blog Updates

Commenting was implemented with the net.nemein.discussion component using the methods described on Midgard site. Since I'm starting to get overwhelmed with spam, commenting my blog posts might be a good way to reach me.

So far all commenters will only be identified as "Anonymous Poster". I might provide some friends later with their own accounts to make moderation easier.

There have also been some background changes, including wider CSS layout box for the MidCOM authoring interface, upgrade to Aegir 1.0.3 nightly and nicer configuration for the HTMLAREA editor. Now the toolbar includes image insertion and <blockquote /> support:

Updated 2004-06-16: Here is the toolbar configuration snippet from /sitegroup-config /midcom.helper.datamanager.widget_html /config:

$nav = new midcom_helper_nav($GLOBALS["view_contentmgr"]->viewdata["context"]);
$leafid = $nav->get_current_leaf();
$leaf = $nav->get_leaf($leafid);
$leaftrueid = explode('/',$leaf[MIDCOM_NAV_URL]);
$leaftrueid = $leaftrueid[1];

$result = <<<EOF

// FIELD {$this->_fieldname} HTMLAREA init script START
var {$this->_fieldname} = null;

function {$this->_fieldname}_init() {

if (!document.getElementById("{$this->_fieldname}")) {

config = new HTMLArea.Config();
config.imgURL = "{$prefix['images']}";
config.popupURL = "{$prefix['htmlarea']}popups/";
config.bodyStyle = "background-color: #fff;";
config.statusBar = false;
config.formatblock = {
"Heading 2": "h2",
"Heading 3": "h3",
"Normal": "p",
"Quote": "blockquote",
"Formatted": "pre"

config.registerButton("insertimage2", "Lisää kuva", "29eda1118f1e58028a3198e2a9c77271/ed_image.gif", false,
function(editor, id) {

chooser = window.open("/aegir/rcs/image/popup/?type=article&id=$leaftrueid&htmlarea=Y&hostid=", "chooser","height=450,width=400,modal=yes");
chooser.ifield = editor;


config.toolbar = [
[ "formatblock", "bold", "italic", "separator",
"justifyleft", "justifycenter", "justifyright", "separator",
"insertorderedlist", "insertunorderedlist", "outdent", "indent", "separator",
"createlink", "insertimage2", "inserttable", "htmlmode","popupeditor"]

{$this->_fieldname} = new HTMLArea("{$this->_fieldname}",config);

// FIELD {$this->_fieldname} HTMLAREA init script END