Roxen.git
/
server
/
etc
/
modules
/
Roxen.pmod
version
»
Context lines:
10
20
40
80
file
none
3
Roxen.git/server/etc/modules/Roxen.pmod:1:
// This is a roxen pike module. Copyright © 1999 - 2001, Roxen IS. //
-
// $Id: Roxen.pmod,v 1.
128
2001/
10
/
08
06
:
07
:
41
per
Exp $
+
// $Id: Roxen.pmod,v 1.
129
2001/
11
/
05
13
:
34
:
09
grubba
Exp $
#include <roxen.h> #include <config.h> #include <version.h> #include <module.h> #include <variables.h> #include <stat.h> #define roxen roxenp() #ifdef HTTP_DEBUG
Roxen.git/server/etc/modules/Roxen.pmod:179:
s+="</tt>"; } else { s+="--"; } return s; } mapping add_http_header(mapping to, string name, string value) { if(to[name]) {
-
if(arrayp(to[name]))
+
if(arrayp(to[name]))
{
+
if (search(to[name], value) == -1)
to[name] += ({ value });
-
else
+
}
else
{
+
if (to[name] != value)
to[name] = ({ to[name], value }); }
-
+
}
else to[name] = value; return to; } int is_mysql_keyword( string name ) //! Return true if the argument is a mysql keyword. //! Not in DBManager due to recursive module dependencies. { return (<
Roxen.git/server/etc/modules/Roxen.pmod:2061:
function get_client_charset_decoder( string åäö, RequestID|void id ) //! Returns a decoder for the clients charset, given the clients //! encoding of the string "åäö". See the roxen-automatic-charset-variable //! tag. { switch( (åäö/"\0")[0] ) { case "edv": report_notice( "Warning: Non 8-bit safe client detected (%s)",
-
(id?id->client*"":"unknown client"));
+
(id?id->client*"
":"unknown client"));
return 0; case "åäö": return 0; case "\33-Aåäö": id && id->set_output_charset && id->set_output_charset( "iso-2022" ); return _charset_decoder(Locale.Charset.decoder("iso-2022-jp"))->decode;
-
+
case "+AOUA5AD2-":
+
id && id->set_output_charset && id->set_output_charset( "utf-7" );
+
return _charset_decoder(Locale.Charset.decoder("utf-7"))->decode;
+
case "åäö": case "åä": id && id->set_output_charset && id->set_output_charset( "utf-8" ); return utf8_to_string; case "\214\212\232": id && id->set_output_charset && id->set_output_charset( "mac" ); return _charset_decoder( Locale.Charset.decoder( "mac" ) )->decode; case "\0å\0ä\0ö":