Changeset 313


Ignore:
Timestamp:
Dec 29, 2003, 4:26:06 PM (18 years ago)
Author:
kake
Message:

Fixes to make URLs be valid for nodes with spaces in.

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/templates/delete_confirm.tt

    r312 r313  
    22<h1>Confirm Deletion</h1>
    33<p>
    4 Are you sure you want to delete <em>[% name %]</em>? If so, please enter the admin
    5 password. If not, you can <a href="[% cgi_url %]?[% name %]">go back to the
     4Are you sure you want to delete <em>[% node_name %]</em>? If so, please enter the admin
     5password. If not, you can <a href="[% cgi_url %]?[% node_param %]">go back to the
    66page</a>.
    77</p>
    88<form action="[% cgi_url %]" method="post">
    99<input type="hidden" name="action" value="delete">
    10 <input type="hidden" name="id" value="[% name %]">
     10<input type="hidden" name="id" value="[% node_name %]">
    1111<strong>Password:</strong> <input type="password" name="password"> <input type="submit" value="Delete">
    1212</form>
  • trunk/templates/delete_done.tt

    r312 r313  
    22<h1>Deleted</h1>
    33<p>
    4 The node '[% name %]' was deleted.
     4The node '[% node_name %]' was deleted.
    55</p>
    66[% INCLUDE footer.tt %]
  • trunk/templates/delete_password_wrong.tt

    r312 r313  
    33<p>
    44Sorry, that was not the correct password. Please <a href="[%
    5 cgi_url %]?id=[% name %];action=delete">try again</a>.
     5cgi_url %]?id=[% node_param %];action=delete">try again</a>.
    66</p>
    77[% INCLUDE footer.tt %]
  • trunk/wiki.cgi

    r312 r313  
    442442    my $node = shift;
    443443
    444     my %tt_vars = ( name => $node );
    445 
    446444    my $password = $q->param('password');
    447445
    448446    if ($password) {
    449447        if ($password ne $config->{_}->{admin_pass}) {
    450             process_template("delete_password_wrong.tt", $node, \%tt_vars)
     448            process_template("delete_password_wrong.tt", $node);
    451449        } else {
    452450            $wiki->delete_node($node);
    453             process_template("delete_done.tt", $node, \%tt_vars);
     451            process_template("delete_done.tt", $node);
    454452        }
    455453    } else {
    456         process_template("delete_confirm.tt", $node, \%tt_vars);
     454        process_template("delete_confirm.tt", $node);
    457455    }
    458456}
Note: See TracChangeset for help on using the changeset viewer.