Revision eb1efd21
Von Moritz Bunkus vor fast 14 Jahren hinzugefügt
SL/Controller/Base.pm | ||
---|---|---|
19 | 19 |
my %params = @_; |
20 | 20 |
my $controller = delete($params{controller}) || $self->_controller_name; |
21 | 21 |
my $action = delete($params{action}) || 'dispatch'; |
22 |
$params{action} = "${controller}::${action}";
|
|
22 |
$params{action} = "${controller}/${action}";
|
|
23 | 23 |
my $query = join('&', map { $::form->escape($_) . '=' . $::form->escape($params{$_}) } keys %params); |
24 | 24 |
|
25 | 25 |
return "controller.pl?${query}"; |
SL/Dispatcher.pm | ||
---|---|---|
282 | 282 |
my ($controller, $action); |
283 | 283 |
|
284 | 284 |
eval { |
285 |
$::form->{action} =~ m|^ ( [A-Z] [A-Za-z0-9_]* ) :: ( [a-z] [a-z0-9_]* ) $|x || die "Unroutable request -- inavlid controller/action.\n";
|
|
285 |
$::form->{action} =~ m|^ ( [A-Z] [A-Za-z0-9_]* ) / ( [a-z] [a-z0-9_]* ) $|x || die "Unroutable request -- inavlid controller/action.\n";
|
|
286 | 286 |
($controller, $action) = ($1, $2); |
287 | 287 |
delete $::form->{action}; |
288 | 288 |
|
Auch abrufbar als: Unified diff
Trennzeichen für Controller-Routing von :: auf / geändert
Conflicts: