Enabled the ability to use slashes in page urls to emulate directory hierarchies.
This commit is contained in:
parent
8b1a43f500
commit
6426950192
2 changed files with 8 additions and 6 deletions
|
|
@ -50,11 +50,12 @@ sub gateway {
|
|||
sub makeCompliant {
|
||||
my ($value);
|
||||
$value = $_[0];
|
||||
$value =~ s/\s+$//g; #removes trailing whitespace
|
||||
$value =~ s/^\s+//g; #removes leading whitespace
|
||||
$value =~ s/ /_/g; #replaces whitespace with underscores
|
||||
$value =~ s/\.$//g; #removes trailing period
|
||||
$value =~ s/[^A-Za-z0-9\-\.\_]//g; #removes all funky characters
|
||||
$value =~ s/\s+$//; #removes trailing whitespace
|
||||
$value =~ s/^\s+//; #removes leading whitespace
|
||||
$value =~ s/^\\//; #removes leading slash
|
||||
$value =~ s/ /_/g; #replaces whitespace with underscores
|
||||
$value =~ s/\.$//; #removes trailing period
|
||||
$value =~ s/[^A-Za-z0-9\-\.\_\\]//g; #removes all funky characters
|
||||
return $value;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue