break; case 2: $violation_category = $l->g('insult'); break; case 3: $violation_category = $l->g('adult_content'); break; case 4: $violation_category = $l->g('illegal_content'); break; case 5: $violation_category = $l->g('harassment'); break; case 6: $violation_category = $l->g('fraud'); break; case 7: default: $violation_category = $l->g('other'); break; } // Send an email $email_body = $l->g('date') . ":\n\t" . $tmp_user->makeDate(time()) . "\n" . $l->g('room_name') . ":\n\t" . $current_room_name . "\n" . $l->g('author') . ":\n\t" . $nickname->coloredToPlain($current_nickname, false) . "\n" . $l->g('violation_category') . ":\n\t" . $violation_category . "\n" . $l->g('abuser_nickname') . ":\n\t" . $abuse_nickname . "\n" . $l->g('violation_description') . ":\n\n" . $abuse_description . "\n"; PCPIN_Email::send('"' . $session->_conf_all['chat_email_sender_name'] . '"' . ' <' . $session->_conf_all['chat_email_sender_address'] . '>', $tmp_user->email, $session->_conf_all['chat_name'] . ': ' . $l->g('abuse_arrived'), null, null, $email_body); } if ($old_language_id != $l->id) { // Restore original language $l->setLanguage($old_language_id); } } }
$current_user->_db_loadObj($session->_s_user_id); if ($current_user->is_admin !== 'y') { $session->_s_logOut(true); header('Location: ' . PCPIN_FORMLINK); die; } } /** * Receive version update information */ if (!empty($sk) && !empty($nv) && !empty($dl)) { _pcpin_loadClass('version'); $version = new PCPIN_Version($session); if ($version->_db_getList(1)) { $current_version = $version->_db_list[0]['version']; $last_check = $version->_db_list[0]['last_version_check'] > '0000-00-00 00:00:00' ? $current_user->makeDate(PCPIN_Common::datetimeToTimestamp($version->_db_list[0]['last_version_check'])) : $l->g('never'); $new_version_available = $version->_db_list[0]['new_version_available']; $new_version_url = $version->_db_list[0]['new_version_url']; $version_check_key = $version->_db_list[0]['version_check_key']; } else { $current_version = 6.0; $last_check = $l->g('never'); $new_version_available = $current_version; $new_version_url = ''; $version_check_key = PCPIN_Common::randomString(mt_rand(10, 20)); } $version->_db_freeList(); // Check security key if (!empty($version_check_key) && md5($sk) == $version_check_key) { if ($session->_db_getList('_s_id', '_s_security_code = ' . $version_check_key, 1)) { // Security key check passed