From 1e94eab2b417f973364a713adbfaa2693ed55eec Mon Sep 17 00:00:00 2001 From: "bbaetz%student.usyd.edu.au" <> Date: Mon, 19 Aug 2002 20:59:39 +0000 Subject: Big 163291 - Move utility funcs into a module r=preed x2 --- CGI.pl | 27 ++------------------------- 1 file changed, 2 insertions(+), 25 deletions(-) (limited to 'CGI.pl') diff --git a/CGI.pl b/CGI.pl index ec4ddedfb..2a10a335a 100644 --- a/CGI.pl +++ b/CGI.pl @@ -33,6 +33,8 @@ use lib "."; # use Carp; # for confess +use Bugzilla::Util; + # commented out the following snippet of code. this tosses errors into the # CGI if you are perl 5.6, and doesn't if you have perl 5.003. # We want to check for the existence of the LDAP modules here. @@ -334,31 +336,6 @@ sub ValidateComment { } } -sub html_quote { - my ($var) = (@_); - $var =~ s/\&/\&/g; - $var =~ s//\>/g; - $var =~ s/"/\"/g; - return $var; -} - -sub value_quote { - my ($var) = (@_); - $var =~ s/\&/\&/g; - $var =~ s//\>/g; - $var =~ s/"/\"/g; - # See bug http://bugzilla.mozilla.org/show_bug.cgi?id=4928 for - # explanaion of why bugzilla does this linebreak substitution. - # This caused form submission problems in mozilla (bug 22983, 32000). - $var =~ s/\r\n/\ /g; - $var =~ s/\n\r/\ /g; - $var =~ s/\r/\ /g; - $var =~ s/\n/\ /g; - return $var; -} - # Adds elements for bug lists. These can be inserted into the header by # using the "header_html" parameter to PutHeader, which inserts an arbitrary # string into the header. This function is currently used only in -- cgit v1.2.3-24-g4f1b