+ elsif ($do eq 'blog') {
+ my $page=titlepage(lc($q->param('title')));
+ # if the page already exists, munge it to be unique
+ my $from=$q->param('from');
+ my $add="";
+ while (exists $oldpagemtime{"$from/$page$add"}) {
+ $add=1 unless length $add;
+ $add++;
+ }
+ $q->param('page', $page.$add);
+ # now run same as create
+ $q->param('do', 'create');
+ cgi_editpage($q, $session);
+ }