]> sipb.mit.edu Git - ikiwiki.git/blobdiff - IkiWiki/Plugin/smcvpostcomment.pm
smcvpostcomment: reduce length of subject field
[ikiwiki.git] / IkiWiki / Plugin / smcvpostcomment.pm
index 367f2d9b3c56a5fcc881c5acf33208c985ddf711..59f0e8cfc9f5cf09b72bb75ab05c2c6960b975d3 100644 (file)
@@ -149,7 +149,7 @@ sub sessioncgi ($$) { #{{{
        $form->field(name => 'sid', type => 'hidden', value => $session->id,
                force => 1);
        $form->field(name => 'page', type => 'hidden');
-       $form->field(name => 'subject', type => 'text', size => 80);
+       $form->field(name => 'subject', type => 'text', size => 72);
        $form->field(name => 'body', type => 'textarea', rows => 5,
                cols => 80);
 
@@ -215,6 +215,8 @@ sub sessioncgi ($$) { #{{{
        # - this means that if they do, rocks fall and everyone dies
 
        if ($form->submitted eq PREVIEW) {
+               # $fake is a location that has the same number of slashes
+               # as the eventual location of this comment.
                my $fake = "$page/_" . PLUGIN . "hypothetical";
                my $preview = IkiWiki::htmlize($fake, $page, 'mdwn',
                                IkiWiki::linkify($page, $page,