diff options
author | gerv%gerv.net <> | 2002-09-21 22:17:03 +0000 |
---|---|---|
committer | gerv%gerv.net <> | 2002-09-21 22:17:03 +0000 |
commit | 66493d5e7e811c387faefd8f27edadcaf762c829 (patch) | |
tree | 20cf654b57eb3fdbcd225ab9396dc48bc1d3c243 /page.cgi | |
parent | a29e0e0640faad00f8c1bf792b93260047f16956 (diff) | |
download | bugs-66493d5e7e811c387faefd8f27edadcaf762c829.tar bugs-66493d5e7e811c387faefd8f27edadcaf762c829.tar.gz bugs-66493d5e7e811c387faefd8f27edadcaf762c829.tar.bz2 bugs-66493d5e7e811c387faefd8f27edadcaf762c829.tar.xz bugs-66493d5e7e811c387faefd8f27edadcaf762c829.zip |
Bug 108987 - Linkify script to use quoteUrls on texts provided by user. Patch by gerv; r=kiko.
Diffstat (limited to 'page.cgi')
-rwxr-xr-x | page.cgi | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -39,11 +39,14 @@ ConnectToDatabase(); quietly_check_login(); -if (defined $::FORM{'id'}) { +if ($::FORM{'id'}) { + # Remove all dodgy chars, and split into name and ctype. $::FORM{'id'} =~ s/[^\w\-\.]//g; - $::FORM{'id'} =~ /(.*)(\.(.*))?/; + $::FORM{'id'} =~ /(.*)\.(.*)/; - my $format = GetFormat($1, undef, $3); + my $format = GetFormat($1, undef, $2); + + $vars->{'form'} = \%::FORM; print "Content-Type: $format->{'ctype'}\n\n"; |