<br><b>version '.$G_brisk_version.'</b><br><br>
Copyright 2006-2012 <a href=\\"mailto:brisk@alternativeoutput.it\\">Matteo Nastasi</a> (aka mop)<br><br>');
+function addrtoipv4($addr)
+{
+ $ipv4addr_arr = explode(':' , $addr);
+ if (isset($ipv4addr_arr[3])) {
+ $ipv4addr = $ipv4addr_arr[3];
+ }
+ else {
+ $ipv4addr = $addr;
+ }
+ return $ipv4addr;
+}
+
function mop_flush()
{
for ($i = 0; $i < ob_get_level(); $i++)
/*
* MAIN
*/
-function bin5_index_wr_main(&$bri, $remote_addr, $get, $post, $cookie)
+function bin5_index_wr_main(&$bri, $remote_addr_full, $get, $post, $cookie)
{
GLOBAL $G_base, $G_dbasetype;
+ $remote_addr = addrtoipv4($remote_addr_full);
+
$curtime = time();
if ($bri == NULL) {
return FALSE;
$room->garbage_manager(TRUE);
/* try login */
- $ipv4addr_arr = explode(':' , $addr);
- if (isset($ipv4addr_arr[3])) {
- $ipv4addr = $ipv4addr_arr[3];
- }
- else {
- $ipv4addr = $addr;
- }
+
+ $ipv4addr = addrtoipv4($addr);
if (($user = $room->add_user(&$sess, &$idx, $name, $pass_private, $ipv4addr, $cookie)) != FALSE) {
$ACTION = "room";
if ($idx < 0) {
);
-function index_wr_main(&$room, $remote_addr, $get, $post, $cookie)
+function index_wr_main(&$room, $remote_addr_full, $get, $post, $cookie)
{
GLOBAL $G_shutdown, $G_black_list, $G_lang, $G_room_help, $G_room_about, $G_room_passwdhowto, $mlang_indwr;
+ $remote_addr = addrtoipv4($remote_addr_full);
+
log_load("index_wr.php");
if (($mesg = gpcs_var('mesg', $get, $post, $cookie)) === FALSE)