function BoomTempLatees($getpage, $boom = '') {
global $mysqli, $setting, $data, $lang;
$page = BOOM_PATH . '/system/template/' . $getpage . '.php';
$structure = '';
ob_start();
require($page);
$structure = ob_get_clean();
return $structure;
}
function createpagaFrames($content, $max, $custom = array()){
global $lang;
$pag = '';
$elem = [];
$control = '';
$state = 1;
$count = 0;
$def = array(
'template' => 'element/empty_element',
'empty' => emptyZone($lang['empty']),
'menu' => 'centered_element',
'content' => '',
'style' => 'list',
);
$r = array_merge($def, $custom);
if((is_array($content) && count($content) > 0) || (is_object($content) && $content->num_rows > 0)){
foreach($content as $e){
if($count == $max){
$state++;
$count = 0;
}
if(!isset($elem[$state])){
$elem[$state] = '';
}
$elem[$state] .= BoomTempLatees($r['template'], $e);
$count++;
}
foreach($elem as $key => $value){
$hide = ($key > 1) ? 'hidden' : '';
$pag .= '<div class="pagzone ' . $r['content'] . ' pagitem' . $key . ' ' . $hide . '">' . $value . '</div>';
}
$pag_data = [
'state'=> $state,
'menu'=> $r['menu'],
'content'=> $pag,
'id'=> rand(1111111,9999999),
'style'=> $r['style'],
];
switch($r['style']){
case 'list': return boomTemplate('element/pag_list', $pag_data);
case 'load': return boomTemplate('element/pag_load', $pag_data);
case 'arrow': return boomTemplate('element/pag_arrow', $pag_data);
case 'dot': return boomTemplate('element/pag_dot', $pag_data);
default: return boomTemplate('element/pag_arrow', $pag_data);
}
}
else {
return $r['empty'];
}
}
function frames_box_list(){
global $mysqli;
global $data;
global $lang;
$list = "";
$gifts = $mysqli->query("SELECT * FROM avatar_frame ORDER BY id ASC");
$list = createpagaFrames($gifts, 15, array('template'=> 'frame_item', 'style'=> 'arrow'));
return $list;
}
function frameTemplate($target, $boom = '') {
global $mysqli, $data, $lang;
return boomTemplate('template/' . $target, $boom);
}
function get_box(){
global $mysqli;
global $data;
global $lang;
return frameTemplate("frame_box");
}
function get_frame($id) {
global $mysqli;
global $lang;
$gift = "";
$gifts = $mysqli->query("SELECT * FROM avatar_frame where id = '" . $id . "' limit 1");
if (0 < $gifts->num_rows) {
$gift = $gifts->fetch_assoc();
}
return $gift;
}
function saveFramesSetting() {
global $mysqli;
$set_access = escape($_POST["set_access"]);
$mysqli->query("UPDATE boom_setting SET user_kisisel_cerceve_rank = '" . $set_access . "' WHERE id = '1'");
boomSaveSettings();
return 1;
}
function edit_frame() {
global $mysqli;
global $data;
global $lang;
$gift = escape($_POST["edit_frame"]);
$gift = get_frame($gift);
$list = frameTemplate("frame_edit_box", $gift);
return $list;
}
function save_frame() {
global $mysqli;
$id = escape($_POST["save_frame"]);
$price = escape($_POST["save_price"]);
$mysqli->query("UPDATE `avatar_frame` SET price = '" . $price . "' WHERE id = '" . $id . "' ");
return 1;
}
function get_next() {
global $mysqli;
global $data;
global $lang;
$current = (int) escape($_POST["get_next"]);
$page = (int) escape($_POST["page"]);
$list = "";
$gifts = $mysqli->query("SELECT * FROM avatar_frame Where id > " . $current . " ORDER BY id ASC limit 15");
if (0 < $gifts->num_rows) {
$page = $page + 1;
$list .= "<div id=\"page_" . $page . "\">";
while ($gift = $gifts->fetch_assoc()) {
$list .= frameTemplate("frame_item", $gift);
}
$list .= "</div>";
}
return $list;
}
function gift_add_box() {
global $mysqli;
global $data;
global $lang;
return frameTemplate("frame_add");
}
function delete_frame() {
global $data;
global $mysqli;
$target = escape($_POST["delete_frame"]);
$frame = get_frame($target);
@unlink(BOOM_PATH . "/default_images/frames/" . $frame["tumb"]);
$mysqli->query("DELETE FROM avatar_frame WHERE id ='" . $frame["id"] . "'");
return $target;
}
function add_frame() {
global $mysqli;
global $data;
global $lang;
ini_set("memory_limit", "128M");
if (fileError()) {
return boomCode(2, ["data" => ""]);
}
$price = escape($_POST["add_price"]);
$finfo = pathinfo($_FILES["file"]["name"]);
$extension = $finfo["extension"];
if (isImage($extension)) {
$imginfo = getimagesize($_FILES["file"]["tmp_name"]);
if ($imginfo !== false) {
$fname = uniqid() . . $extension;
boomMoveFile("default_images/frames/" . $fname);
$source = "default_images/frames/" . $fname;
if (sourceExist($source) && validImageData($source)) {
$mysqli->query("INSERT INTO `avatar_frame` (`price`, `tumb`) VALUES ('" . $price . "','" . $fname . "')");
return 1;
}
}
}
return 2;
}
function frames_list_admin() {
global $mysqli, $data, $lang;
$list = [];
if (($cache = redisGetObject('avatar_frame:list'))) {
return createPag($cache, 24, array('template' => '../system/template/frame_item_admin', 'style' => 'list'));
}
$frames = $mysqli->query("SELECT * FROM avatar_frame ORDER BY id ASC");
if ($frames->num_rows > 0) {
while ($frame = $frames->fetch_assoc()) {
$list[] = $frame;
}
redisSetObject('avatar_frame:list', $list);
}
return createPag($list, 24, array('template' => '../system/template/frame_item_admin', 'style' => 'arrow'));
}
function unset_frame() {
global $data;
global $mysqli;
$mysqli->query("UPDATE boom_users SET avatar_frame = '' WHERE user_id = '" . $data["user_id"] . "'");
redisUpdateUser($data['user_id']);
return 1;
}
function set_frame() {
global $mysqli;
global $data;
$frame = escape($_POST["set_frame"]);
$item = get_frame($frame);
if ($item["tumb"] == $data["avatar_frame"]) {
return 1;
}
$price = $item["price"];
$tumb = $item["tumb"];
if ($price == 0 || boomAllow(100)) {
$mysqli->query("UPDATE boom_users SET avatar_frame = '" .$tumb . "' WHERE user_id = '" . $data["user_id"] . "'");
redisUpdateUser($data['user_id']);
return 1;
}
if ($price <= $data["user_gold"]) {
$gold = $data["user_gold"] - $item["price"];
$mysqli->query("UPDATE boom_users SET user_gold = '" . $gold . "'avatar_frame = '" . $frame . "' WHERE user_id = '" . $data["user_id"] . "'");
redisUpdateUser($data['user_id']);
return 1;
}
return 3;
}
function createUserlistYonetim($list, $lazy = false){
if(!isVisible($list)){
return false;
}
$status = '';
$moood = '';
if($lazy){
$avatar = '<img class="lazy avav acav ' . genderBorder($list['user_sex']) . '" data-src="' . myAvatar($list['user_tumb']) . '" src="' . imgLoader() . '"/>';
}
else {
$avatar = '<img class="avav acav ' . genderBorder($list['user_sex']) . '" src="' . myAvatar($list['user_tumb']) . '"/>';
}
if(!empty($list['user_mood'])){
$moood = '<p class="text_xsmall bustate bellips">'.$list['user_mood'].'</p>';
} else {
$moood = '<p class="text_xsmall bustate bellips" style="font-weight:bold; border: 1px solid; width: fit-content; border-radius:0.5rem; padding:2px 3px; font-size:12px;">'.rankTitle($list['user_rank']).'</p>';
}
return '<div class="avtrig get_info bhover user_item" data="' . $list["user_id"] . '">
<div class="user_item_avatar">' . $avatar . ' ' . $status . '</div>
<div class="user_item_data">
<p class="username ' . myColorFont($list) . '">' . $list["user_name"] . '</p>
'.$moood.'
</div>
' . getListAction($list). '
<div class="user_item_icon mini_icon icrank">
' . userListRank($list) . '
</div>
</div>';
}
function getYonetimListDetay(){
global $mysqli;
$a = $mysqli->query("SELECT
( SELECT count(user_id) FROM boom_users WHERE user_bot = 0) as user_count,
( SELECT count(user_id) FROM boom_users WHERE user_sex = 2 AND user_bot = 0) as female_count,
( SELECT count(user_id) FROM boom_users WHERE user_sex = 1 AND user_bot = 0 ) as male_count");
$b = $a->fetch_assoc();
return $b;
}
function bildirimrank(){
global $setting;
if(boomAllow(90)){
return true;
}else{
return false;
}
}
function UserDefaultFlash($sel, $type, $min = 1){
global $data;
$show_c = '';
switch($type){
case 4:
$c = 'pro_choice';
break;
default:
return false;
}
for ($n = $min; $n <= 15; $n++) {
$val = 'defaultflash' . $n;
$back = 'defaultflash' . $n;
$add_sel = '';
if($val == $sel){
$add_sel = 'TesT';
}
$show_c .= '<ul><li data="' . $val . '" class="default_flash_select ' . $c . ' ' . $back . '">' . $data['user_name'] . '</li></ul>';
}
return $show_c;
}
function ChatpopulerRoomlist(){
global $mysqli, $data, $lang;
$chatpopulerroomlist = '';
$owner = '';
$ask = 0;
$proom_list = $mysqli->query("SELECT * FROM boom_rooms WHERE room_populer = 1 ORDER BY room_action DESC LIMIT 4");
if($proom_list->num_rows > 0){
while($proom = $proom_list->fetch_assoc()){
if($proom['password'] != ''){
$ask = 1;
} else {
$ask = 0;
}
if($data['user_id'] == $proom['room_creator']){
$owner = 'owner ';
}
$proom_listt = $mysqli->query("SELECT * FROM boom_rooms WHERE room_populer = 1 ORDER BY room_action DESC LIMIT 1");
if($proom_listt->num_rows > 0){
while($proomm = $proom_listt->fetch_assoc()){
if($proomm['room_populer'] == 1){
$chatpopulerroomlistt = '<div class="div-baslik text_micro"><span>'.$lang['populer_odalar'].'</span></div>';
} else {
$chatpopulerroomlistt = '';
}
}
}
if($proom['room_populer'] == 1){
$chatpopulerroomlist .= '<div class="room_square_elem" onclick="switchRoom(' . $proom['room_id'] . ', ' .$ask. ',' .$proom['access']. ');">
<img class="lazy" data-src="'.myRoomIcon($proom['room_icon']).'" src="'.imgLoader().'">
<div class="square_name lite_olay"> '.$proom['room_name'].'</div>
</div>';
} else {
$chatpopulerroomlist .= '';
}
}
}
echo @$chatpopulerroomlistt;
echo @$chatpopulerroomlist;
}
function RoomPopuler($room){
if($room['room_populer'] > 0){
return true;
}
}
function RoomOwnerList($curr, $tur) {
global $mysqli, $lang;
$roomowner = '';
if($tur == 1){
$roomowner .= '<option value="' . $lang['oda_sahibi_yok'] . '">' . $lang['oda_sahibi_yok'] . '</option>';
}
$owner_list = $mysqli->query("SELECT * FROM boom_users WHERE user_bot = 0 AND onay = 1");
if($owner_list->num_rows > 0){
while($owner = $owner_list->fetch_assoc()){
$roomowner .= '<option value="' . $owner['user_name'] . '" ' . selCurrent($curr, $owner['user_name']) . '>' . $owner['user_name'] . '</option>';
}
}
return $roomowner;
}
function RoomOwnerListNew($tur) {
global $mysqli, $lang;
$roomowner = '';
if($tur == 1){
$roomowner .= '<option value="' . $lang['oda_sahibi_yok'] . '">' . $lang['oda_sahibi_yok'] . '</option>';
}
$owner_list = $mysqli->query("SELECT * FROM boom_users WHERE user_bot = 0 AND onay = 1");
if($owner_list->num_rows > 0){
while($owner = $owner_list->fetch_assoc()){
$roomowner .= '<option value="' . $owner['user_name'] . '">' . $owner['user_name'] . '</option>';
}
}
return $roomowner;
}
function boomTemplates($getpage, $boom = '') {
global $data, $lang, $mysqli;
$page = BOOM_PATH . $getpage . '.php';
$structure = '';
ob_start();
require($page);
$structure = ob_get_contents();
return $structure;
}
function goldKural(){
global $mysqli, $data, $setting;
if(boomAllow(100)){
return true;
} else if(($data['user_gold'] - 500) >= 1000){
$mysqli->query("UPDATE boom_users SET user_gold = user_gold - 500 WHERE user_id = '{$data['user_id']}'");
redisUpdateUser($data['user_id']);
return true;
}
}
function smspanellist(){
global $mysqli, $data, $lang;
$smspanellist = '';
$sms_list = $mysqli->query("SELECT * from boom_sms where yayinla = '1'");
if($sms_list->num_rows > 0){
while($smspanel = $sms_list->fetch_assoc()){
$user = userDetails($smspanel['post_user']);
$smspanellist .= '<span style="color:#00dcff;">'.$user['user_name'].'</span> - <span style="color:#ffd400;"> '.$smspanel['post_content'].'</span> ';
}
} else {
$smspanellist .= '<span style="color:#ffeb00;"> '.$lang['empty'].'</span>';
}
echo $smspanellist;
}
function adminsmspanelyetki(){
global $setting;
if(boomAllow(90)){
return true;
}else{
return false;
}
}
function smsgondermeyetki(){
global $setting;
if(boomAllow(50)){
return true;
}else{
return false;
}
}
function kisiselarkaplan($b, $c = 1) {
global $data, $setting;
$d = '';
$b = explode(" ", $data['user_oda_fon']);
for ($n = $c; $n <= 12; $n++) {
$e = 'odaarkaplan' . $n;
$f = '';
if ($e == $b[0]) {
$f = 'kisisel_arkaplan_aktif_olan';
}
$d .= '<li><img data="' . $e . '" class="' . $f . ' kisiselarkaplan_choice lazy" data-src="'.$setting['domain'].'/default_images/odaarkaplan/' . $e . '.png" src="'.imgLoader().'"></li>';
}
return $d;
}
function encoderoomFileTumb($ext, $user){
global $data;
$file_name = md5(microtime());
$file_name = substr($file_name, 0, 12);
$fname['full'] = 'room_' . $user['user_roomid'] . '_' . $file_name . . $ext;
$fname['tumb'] = 'room_' . $user['user_roomid'] . '_' . $file_name . '_tumb.'. $ext;
return $fname;
}
function isRoomBgImage($ext){
$ext = strtolower($ext);
$img = array( 'image/gif', 'image/jpeg', 'image/jpg', 'image/pjpeg', 'image/x-png', 'image/png', 'image/JPG', 'image/webp' );
$img_ext = array( 'gif', 'jpeg', 'jpg', 'JPG', 'PNG', 'png', 'x-png', 'pjpeg', 'webp' );
if( in_array($_FILES["file"]["type"], $img) && in_array($ext, $img_ext)){
return true;
}
}
function canGifRoomBg(){
if(boomAllow(90)){
return true;
}
}
function myRoombackgrounds($a){
if($a!="") {
$background = 'room_icon/fon/'.$a.'';
} else {
$background = 'default_images/rooms/default_room_background.png';
}
return BOOM_DOMAIN . 'background-image: url(' . $background . ');';
}
function roombackground(){
global $mysqli,$data;
$room_background = $mysqli->query("SELECT room_background FROM boom_rooms WHERE room_id = '{$data['user_roomid']}'");
if($room_background->num_rows > 0){
$room_background = $room_background->fetch_assoc();
if($room_background['room_background']!="") {
$background = myroombackground($room_background['room_background']);
} else {
$background = "default_images/rooms/default_room_background.png";
}
if($room_background['room_background'] != "0"){
return 'style="background-image: url(' . $background . ');background-size: 100% 100%;"';
}
}
}
function canroombackground(){
global $setting;
if(boomAllow($setting['allow_room'])){
return true;
}
}
function roombackgroundClass($room){
global $data;
if(Haveroombackground($room)){
return 'roombackground_size';
}
}
function Haveroombackground($room){
global $data;
if($room['room_background'] != ''){
return true;
}
}
function getroombackground($room){
global $data;
if(Haveroombackground($room)){
return 'style="background-image: url(' . myroombackground($room['room_background']) . ');"';
}
}
function myroombackground($a){
global $setting;
return $setting['domain'] . '/room_icon/fon/' . $a;
}
function unlinkroombackground($file){
$file = trim(str_replace(array('/', '..'), '', $file));
if($file == '' || empty($file)){
return false;
}
$delete = BOOM_PATH . '/room_icon/fon/' . $file;
if(file_exists($delete)){
unlink($delete);
}
}
function resetroombackground($u){
global $mysqli;
$room = roomDetails($u['user_roomid']);
$unlink_roombackground = unlinkroombackground($room['room_background']);
$mysqli->query("UPDATE boom_rooms SET room_background = '' WHERE room_id = '{$u['user_roomid']}'");
boomConsole("remove_roombackground", ["target" => $room["room_id"]]);
redisUpdateRoom($u['user_roomid']);
}
function getMobileIcon($user, $c){
global $lang;
if($user['user_mobile'] > 0){
return '<img title="' . $lang['mobile'] . '" class="' . $c . '" src="default_images/icons/mobile.svg"/>';
}else{
return '<img title="' . $lang['pc'] . '" class="' . $c . '" src="default_images/icons/pc.svg"/>';
}
}
function updateUserCihazDurum() {
global $mysqli, $data;
$mob = getMobile();
$mysqli->query("UPDATE boom_users SET user_mobile = " . $mob . " WHERE user_id = '" . $data["user_id"] . "'");
redisUpdateUser($data['user_id']);
}
function onay(){
global $data;
if($data['onay'] == 1){
return true;
}else{
return false;
}
}
function onaylist($list){
global $data, $setting, $lang;
if(!isVisible($list)){
return false;
}
$mood = '';
$offline = 'offline';
if($list['last_action'] > getDelay() || isBot($list)){
$offline = '';
}
$Yetki = '<p class="text_xsmall bustate bellips"><i class="fa fa-map-marker"></i> ' . $list['user_ip'] . ' | <i class="fa fa-envelope"></i> ' . $list['user_email'] . '</p>';
if($list['user_sex'] == 0){
$cinsiyet = '<div class="user_item_flag"><i class="mdi mdi-gender-male imale imale gendermale gender"></i></div>';
} else if($list['user_sex'] == 1){
$cinsiyet = '<div class="user_item_flag"><i class="mdi mdi-gender-male imale gendermale gender" title="'.$lang['male'].'"></i></div>';
} else if($list['user_sex'] == 2){
$cinsiyet = '<div class="user_item_flag"><i class="mdi mdi-gender-female ifemale genderfemale gender" title="'.$lang['female'].'"></i></div>';
} else if($list['user_sex'] == 3){
$cinsiyet = '<div class="user_item_flag"><i class="mdi mdi-gender-male imale imale gendermale gender"></i></div>';
}
$onay = '<div class="user_item_icon icmute '.$list['user_id'].'" onclick="onayislem('.$list['user_id'].', 1); DivSil(this);"><i class="fa fa-check success"></i></div><div class="user_item_icon icmute '.$list['user_id'].'" onclick="onayislem('.$list['user_id'].', 2); DivSil(this);"><i class="fa fa-close success"></i></div><div class="user_item_icon icmute" onclick="listAction('.$list['user_id'].', \'ban\'); DivSil(this);"><i class="fa fa-ban error"></i></div><div class="user_item_icon icmute" onclick="listAction('.$list['user_id'].', \'delete_account\'); DivSil(this);"><i class="fa fa-trash error"></i></div>';
return '<div data="' . $list['user_id'] . '" class="avtrig user_item ' . $offline . '">
<div data="' . $list['user_id'] . '" class="user_item_avatar get_info"><img class="avav lazy acav" src="' . myAvatar($list['user_tumb']) . '"/> </div>
<div class="user_item_data"><p data="' . $list['user_id'] . '" class="get_info username ' . myColorFont($list) . '">' . $list["user_name"] . '</p>' . $Yetki . '</div>
' . $onay . $cinsiyet. '
</div>';
}
function BoomTempLatees($getpage, $boom = '') {
global $mysqli, $setting, $data, $lang;
$page = BOOM_PATH . '/system/template/' . $getpage . '.php';
$structure = '';
ob_start();
require($page);
$structure = ob_get_clean();
return $structure;
}
function createpagaFrames('pro_choice'ontent, $max, 'pro_choice'ustom = array()){
global $lang;
$pag = '';
$elem = [];
'pro_choice'ontrol = '';
$state = 1;
'pro_choice'ount = 0;
$def = array(
'template' => 'element/empty_element',
'empty' => emptyZone($lang['empty']),
'menu' => 'centered_element',
'content' => '',
'style' => 'list',
);
$r = array_merge($def, 'pro_choice'ustom);
if((is_array('pro_choice'ontent) && count('pro_choice'ontent) > 0) || (is_object('pro_choice'ontent) && 'pro_choice'ontent->num_rows > 0)){
foreach('pro_choice'ontent as $e){
if('pro_choice'ount == $max){
$state++;
'pro_choice'ount = 0;
}
if(!isset($elem[$state])){
$elem[$state] = '';
}
$elem[$state] .= BoomTempLatees($r['template'], $e);
'pro_choice'ount++;
}
foreach($elem as $key => $value){
$hide = ($key > 1) ? 'hidden' : '';
$pag .= '<div class="pagzone ' . $r['content'] . ' pagitem' . $key . ' ' . $hide . '">' . $value . '</div>';
}
$pag_data = [
'state'=> $state,
'menu'=> $r['menu'],
'content'=> $pag,
'id'=> rand(1111111,9999999),
'style'=> $r['style'],
];
switch($r['style']){
case 'list': return boomTemplate('element/pag_list', $pag_data);
case 'load': return boomTemplate('element/pag_load', $pag_data);
case 'arrow': return boomTemplate('element/pag_arrow', $pag_data);
case 'dot': return boomTemplate('element/pag_dot', $pag_data);
default: return boomTemplate('element/pag_arrow', $pag_data);
}
}
else {
return $r['empty'];
}
}
function frames_box_list(){
global $mysqli;
global $data;
global $lang;
$list = "";
$gifts = $mysqli->query("SELECT * FROM avatar_frame ORDER BY id ASC");
$list = createpagaFrames($gifts, 15, array('template'=> 'frame_item', 'style'=> 'arrow'));
return $list;
}
function frameTemplate($target, $boom = '') {
global $mysqli, $data, $lang;
return boomTemplate('template/' . $target, $boom);
}
function get_box(){
global $mysqli;
global $data;
global $lang;
return frameTemplate("frame_box");
}
function get_frame($id) {
global $mysqli;
global $lang;
$gift = "";
$gifts = $mysqli->query("SELECT * FROM avatar_frame where id = '" . $id . "' limit 1");
if (0 < $gifts->num_rows) {
$gift = $gifts->fetch_assoc();
}
return $gift;
}
function saveFramesSetting() {
global $mysqli;
$set_access = escape($_POST["set_access"]);
$mysqli->query("UPDATE boom_setting SET user_kisisel_cerceve_rank = '" . $set_access . "' WHERE id = '1'");
boomSaveSettings();
return 1;
}
function edit_frame() {
global $mysqli;
global $data;
global $lang;
$gift = escape($_POST["edit_frame"]);
$gift = get_frame($gift);
$list = frameTemplate("frame_edit_box", $gift);
return $list;
}
function save_frame() {
global $mysqli;
$id = escape($_POST["save_frame"]);
$price = escape($_POST["save_price"]);
$mysqli->query("UPDATE `avatar_frame` SET price = '" . $price . "' WHERE id = '" . $id . "' ");
return 1;
}
function get_next() {
global $mysqli;
global $data;
global $lang;
'pro_choice'urrent = (int) escape($_POST["get_next"]);
$page = (int) escape($_POST["page"]);
$list = "";
$gifts = $mysqli->query("SELECT * FROM avatar_frame Where id > pro_choice'urrent . " ORDER BY id ASC limit 15");
if (0 < $gifts->num_rows) {
$page = $page + 1;
$list .= "<div id=\"page_" . $page . "\">";
while ($gift = $gifts->fetch_assoc()) {
$list .= frameTemplate("frame_item", $gift);
}
$list .= "</div>";
}
return $list;
}
function gift_add_box() {
global $mysqli;
global $data;
global $lang;
return frameTemplate("frame_add");
}
function delete_frame() {
global $data;
global $mysqli;
$target = escape($_POST["delete_frame"]);
'kisisel_arkaplan_aktif_olan'rame = get_frame($target);
@unlink(BOOM_PATH . "/default_images/frames/kisisel_arkaplan_aktif_olan'rame["tumb"]);
$mysqli->query("DELETE FROM avatar_frame WHERE id ='kisisel_arkaplan_aktif_olan'rame["id"] . "'");
return $target;
}
function add_frame() {
global $mysqli;
global $data;
global $lang;
ini_set("memory_limit", "128M");
if (fileError()) {
return boomCode(2, ["data" => ""]);
}
$price = escape($_POST["add_price"]);
'kisisel_arkaplan_aktif_olan'info = pathinfo($_FILES["file"]["name"]);
$extension = 'kisisel_arkaplan_aktif_olan'info["extension"];
if (isImage($extension)) {
$imginfo = getimagesize($_FILES["file"]["tmp_name"]);
if ($imginfo !== false) {
'kisisel_arkaplan_aktif_olan'name = uniqid() . . $extension;
boomMoveFile("default_images/frames/kisisel_arkaplan_aktif_olan'name);
$source = "default_images/frames/kisisel_arkaplan_aktif_olan'name;
if (sourceExist($source) && validImageData($source)) {
$mysqli->query("INSERT INTO `avatar_frame` (`price`, `tumb`) VALUES ('" . $price . "','kisisel_arkaplan_aktif_olan'name . "')");
return 1;
}
}
}
return 2;
}
function frames_list_admin() {
global $mysqli, $data, $lang;
$list = [];
if (('pro_choice'ache = redisGetObject('avatar_frame:list'))) {
return createPag('pro_choice'ache, 24, array('template' => '../system/template/frame_item_admin', 'style' => 'list'));
}
'kisisel_arkaplan_aktif_olan'rames = $mysqli->query("SELECT * FROM avatar_frame ORDER BY id ASC");
if ('kisisel_arkaplan_aktif_olan'rames->num_rows > 0) {
while ('kisisel_arkaplan_aktif_olan'rame = 'kisisel_arkaplan_aktif_olan'rames->fetch_assoc()) {
$list[] = 'kisisel_arkaplan_aktif_olan'rame;
}
redisSetObject('avatar_frame:list', $list);
}
return createPag($list, 24, array('template' => '../system/template/frame_item_admin', 'style' => 'arrow'));
}
function unset_frame() {
global $data;
global $mysqli;
$mysqli->query("UPDATE boom_users SET avatar_frame = '' WHERE user_id = '" . $data["user_id"] . "'");
redisUpdateUser($data['user_id']);
return 1;
}
function set_frame() {
global $mysqli;
global $data;
'kisisel_arkaplan_aktif_olan'rame = escape($_POST["set_frame"]);
$item = get_frame('kisisel_arkaplan_aktif_olan'rame);
if ($item["tumb"] == $data["avatar_frame"]) {
return 1;
}
$price = $item["price"];
$tumb = $item["tumb"];
if ($price == 0 || boomAllow(100)) {
$mysqli->query("UPDATE boom_users SET avatar_frame = '" .$tumb . "' WHERE user_id = '" . $data["user_id"] . "'");
redisUpdateUser($data['user_id']);
return 1;
}
if ($price <= $data["user_gold"]) {
$gold = $data["user_gold"] - $item["price"];
$mysqli->query("UPDATE boom_users SET user_gold = '" . $gold . "'avatar_frame = 'kisisel_arkaplan_aktif_olan'rame . "' WHERE user_id = '" . $data["user_id"] . "'");
redisUpdateUser($data['user_id']);
return 1;
}
return 3;
}
function createUserlistYonetim($list, $lazy = false){
if(!isVisible($list)){
return false;
}
$status = '';
$moood = '';
if($lazy){
$avatar = '<img class="lazy avav acav ' . genderBorder($list['user_sex']) . '" data-src="' . myAvatar($list['user_tumb']) . '" src="' . imgLoader() . '"/>';
}
else {
$avatar = '<img class="avav acav ' . genderBorder($list['user_sex']) . '" src="' . myAvatar($list['user_tumb']) . '"/>';
}
if(!empty($list['user_mood'])){
$moood = '<p class="text_xsmall bustate bellips">'.$list['user_mood'].'</p>';
} else {
$moood = '<p class="text_xsmall bustate bellips" style="font-weight:bold; border: 1px solid; width: fit-content; border-radius:0.5rem; padding:2px 3px; font-size:12px;">'.rankTitle($list['user_rank']).'</p>';
}
return '<div class="avtrig get_info bhover user_item" data="' . $list["user_id"] . '">
<div class="user_item_avatar">' . $avatar . ' ' . $status . '</div>
<div class="user_item_data">
<p class="username ' . myColorFont($list) . '">' . $list["user_name"] . '</p>
'.$moood.'
</div>
' . getListAction($list). '
<div class="user_item_icon mini_icon icrank">
' . userListRank($list) . '
</div>
</div>';
}
function getYonetimListDetay(){
global $mysqli;
$a = $mysqli->query("SELECT
( SELECT count(user_id) FROM boom_users WHERE user_bot = 0) as user_count,
( SELECT count(user_id) FROM boom_users WHERE user_sex = 2 AND user_bot = 0) as female_count,
( SELECT count(user_id) FROM boom_users WHERE user_sex = 1 AND user_bot = 0 ) as male_count");
$b = $a->fetch_assoc();
return $b;
}
function bildirimrank(){
global $setting;
if(boomAllow(90)){
return true;
}else{
return false;
}
}
function UserDefaultFlash($sel, $type, $min = 1){
global $data;
$show_c = '';
switch($type){
case 4:
break;
default:
return false;
}
for ($n = $min; $n <= 15; $n++) {
$val = 'defaultflash' . $n;
$back = 'defaultflash' . $n;
'TesT' = '';
if($val == $sel){
}
$show_c .= '<ul><li data="' . $val . '" class="default_flash_select pro_choice ' . $back . '">' . $data['user_name'] . '</li></ul>';
}
return $show_c;
}
function ChatpopulerRoomlist(){
global $mysqli, $data, $lang;
'pro_choice'hatpopulerroomlist = '';
$owner = '';
$ask = 0;
$proom_list = $mysqli->query("SELECT * FROM boom_rooms WHERE room_populer = 1 ORDER BY room_action DESC LIMIT 4");
if($proom_list->num_rows > 0){
while($proom = $proom_list->fetch_assoc()){
if($proom['password'] != ''){
$ask = 1;
} else {
$ask = 0;
}
if($data['user_id'] == $proom['room_creator']){
$owner = 'owner ';
}
$proom_listt = $mysqli->query("SELECT * FROM boom_rooms WHERE room_populer = 1 ORDER BY room_action DESC LIMIT 1");
if($proom_listt->num_rows > 0){
while($proomm = $proom_listt->fetch_assoc()){
if($proomm['room_populer'] == 1){
'pro_choice'hatpopulerroomlistt = '<div class="div-baslik text_micro"><span>'.$lang['populer_odalar'].'</span></div>';
} else {
'pro_choice'hatpopulerroomlistt = '';
}
}
}
if($proom['room_populer'] == 1){
'pro_choice'hatpopulerroomlist .= '<div class="room_square_elem" onclick="switchRoom(' . $proom['room_id'] . ', ' .$ask. ',' .$proom['access']. ');">
<img class="lazy" data-src="'.myRoomIcon($proom['room_icon']).'" src="'.imgLoader().'">
<div class="square_name lite_olay"> '.$proom['room_name'].'</div>
</div>';
} else {
'pro_choice'hatpopulerroomlist .= '';
}
}
}
echo @'pro_choice'hatpopulerroomlistt;
echo @'pro_choice'hatpopulerroomlist;
}
function RoomPopuler($room){
if($room['room_populer'] > 0){
return true;
}
}
function RoomOwnerList('pro_choice'urr, $tur) {
global $mysqli, $lang;
$roomowner = '';
if($tur == 1){
$roomowner .= '<option value="' . $lang['oda_sahibi_yok'] . '">' . $lang['oda_sahibi_yok'] . '</option>';
}
$owner_list = $mysqli->query("SELECT * FROM boom_users WHERE user_bot = 0 AND onay = 1");
if($owner_list->num_rows > 0){
while($owner = $owner_list->fetch_assoc()){
$roomowner .= '<option value="' . $owner['user_name'] . '" ' . selCurrent('pro_choice'urr, $owner['user_name']) . '>' . $owner['user_name'] . '</option>';
}
}
return $roomowner;
}
function RoomOwnerListNew($tur) {
global $mysqli, $lang;
$roomowner = '';
if($tur == 1){
$roomowner .= '<option value="' . $lang['oda_sahibi_yok'] . '">' . $lang['oda_sahibi_yok'] . '</option>';
}
$owner_list = $mysqli->query("SELECT * FROM boom_users WHERE user_bot = 0 AND onay = 1");
if($owner_list->num_rows > 0){
while($owner = $owner_list->fetch_assoc()){
$roomowner .= '<option value="' . $owner['user_name'] . '">' . $owner['user_name'] . '</option>';
}
}
return $roomowner;
}
function boomTemplates($getpage, $boom = '') {
global $data, $lang, $mysqli;
$page = BOOM_PATH . $getpage . '.php';
$structure = '';
ob_start();
require($page);
$structure = ob_get_contents();
return $structure;
}
function goldKural(){
global $mysqli, $data, $setting;
if(boomAllow(100)){
return true;
} else if(($data['user_gold'] - 500) >= 1000){
$mysqli->query("UPDATE boom_users SET user_gold = user_gold - 500 WHERE user_id = '{$data['user_id']}'");
redisUpdateUser($data['user_id']);
return true;
}
}
function smspanellist(){
global $mysqli, $data, $lang;
$smspanellist = '';
$sms_list = $mysqli->query("SELECT * from boom_sms where yayinla = '1'");
if($sms_list->num_rows > 0){
while($smspanel = $sms_list->fetch_assoc()){
$user = userDetails($smspanel['post_user']);
$smspanellist .= '<span style="color:#00dcff;">'.$user['user_name'].'</span> - <span style="color:#ffd400;"> '.$smspanel['post_content'].'</span> ';
}
} else {
$smspanellist .= '<span style="color:#ffeb00;"> '.$lang['empty'].'</span>';
}
echo $smspanellist;
}
function adminsmspanelyetki(){
global $setting;
if(boomAllow(90)){
return true;
}else{
return false;
}
}
function smsgondermeyetki(){
global $setting;
if(boomAllow(50)){
return true;
}else{
return false;
}
}
function kisiselarkaplan($b, 'pro_choice' = 1) {
global $data, $setting;
$d = '';
$b = explode(" ", $data['user_oda_fon']);
for ($n = 'pro_choice'; $n <= 12; $n++) {
$e = 'odaarkaplan' . $n;
'kisisel_arkaplan_aktif_olan' = '';
if ($e == $b[0]) {
}
$d .= '<li><img data="' . $e . '" class="kisisel_arkaplan_aktif_olan kisiselarkaplan_choice lazy" data-src="'.$setting['domain'].'/default_images/odaarkaplan/' . $e . '.png" src="'.imgLoader().'"></li>';
}
return $d;
}
function encoderoomFileTumb($ext, $user){
global $data;
'kisisel_arkaplan_aktif_olan'ile_name = md5(microtime());
'kisisel_arkaplan_aktif_olan'ile_name = substr('kisisel_arkaplan_aktif_olan'ile_name, 0, 12);
'kisisel_arkaplan_aktif_olan'name['full'] = 'room_' . $user['user_roomid'] . '_kisisel_arkaplan_aktif_olan'ile_name . . $ext;
'kisisel_arkaplan_aktif_olan'name['tumb'] = 'room_' . $user['user_roomid'] . '_kisisel_arkaplan_aktif_olan'ile_name . '_tumb.'. $ext;
return 'kisisel_arkaplan_aktif_olan'name;
}
function isRoomBgImage($ext){
$ext = strtolower($ext);
$img = array( 'image/gif', 'image/jpeg', 'image/jpg', 'image/pjpeg', 'image/x-png', 'image/png', 'image/JPG', 'image/webp' );
$img_ext = array( 'gif', 'jpeg', 'jpg', 'JPG', 'PNG', 'png', 'x-png', 'pjpeg', 'webp' );
if( in_array($_FILES["file"]["type"], $img) && in_array($ext, $img_ext)){
return true;
}
}
function canGifRoomBg(){
if(boomAllow(90)){
return true;
}
}
function myRoombackgrounds($a){
if($a!="") {
$background = 'room_icon/fon/'.$a.'';
} else {
$background = 'default_images/rooms/default_room_background.png';
}
return BOOM_DOMAIN . 'background-image: url(' . $background . ');';
}
function roombackground(){
global $mysqli,$data;
$room_background = $mysqli->query("SELECT room_background FROM boom_rooms WHERE room_id = '{$data['user_roomid']}'");
if($room_background->num_rows > 0){
$room_background = $room_background->fetch_assoc();
if($room_background['room_background']!="") {
$background = myroombackground($room_background['room_background']);
} else {
$background = "default_images/rooms/default_room_background.png";
}
if($room_background['room_background'] != "0"){
return 'style="background-image: url(' . $background . ');background-size: 100% 100%;"';
}
}
}
function canroombackground(){
global $setting;
if(boomAllow($setting['allow_room'])){
return true;
}
}
function roombackgroundClass($room){
global $data;
if(Haveroombackground($room)){
return 'roombackground_size';
}
}
function Haveroombackground($room){
global $data;
if($room['room_background'] != ''){
return true;
}
}
function getroombackground($room){
global $data;
if(Haveroombackground($room)){
return 'style="background-image: url(' . myroombackground($room['room_background']) . ');"';
}
}
function myroombackground($a){
global $setting;
return $setting['domain'] . '/room_icon/fon/' . $a;
}
function unlinkroombackground('kisisel_arkaplan_aktif_olan'ile){
'kisisel_arkaplan_aktif_olan'ile = trim(str_replace(array('/', '..'), '', 'kisisel_arkaplan_aktif_olan'ile));
if('kisisel_arkaplan_aktif_olan'ile == '' || empty('kisisel_arkaplan_aktif_olan'ile)){
return false;
}
$delete = BOOM_PATH . '/room_icon/fon/kisisel_arkaplan_aktif_olan'ile;
if(file_exists($delete)){
unlink($delete);
}
}
function resetroombackground($u){
global $mysqli;
$room = roomDetails($u['user_roomid']);
$unlink_roombackground = unlinkroombackground($room['room_background']);
$mysqli->query("UPDATE boom_rooms SET room_background = '' WHERE room_id = '{$u['user_roomid']}'");
boomConsole("remove_roombackground", ["target" => $room["room_id"]]);
redisUpdateRoom($u['user_roomid']);
}
function getMobileIcon($user, 'pro_choice'){
global $lang;
if($user['user_mobile'] > 0){
return '<img title="' . $lang['mobile'] . '" class="pro_choice" src="default_images/icons/mobile.svg"/>';
}else{
return '<img title="' . $lang['pc'] . '" class="pro_choice" src="default_images/icons/pc.svg"/>';
}
}
function updateUserCihazDurum() {
global $mysqli, $data;
$mob = getMobile();
$mysqli->query("UPDATE boom_users SET user_mobile = " . $mob . " WHERE user_id = '" . $data["user_id"] . "'");
redisUpdateUser($data['user_id']);
}
function onay(){
global $data;
if($data['onay'] == 1){
return true;
}else{
return false;
}
}
function onaylist($list){
global $data, $setting, $lang;
if(!isVisible($list)){
return false;
}
$mood = '';
if($list['last_action'] > getDelay() || isBot($list)){
'offline' = '';
}
$Yetki = '<p class="text_xsmall bustate bellips"><i class="fa fa-map-marker"></i> ' . $list['user_ip'] . ' | <i class="fa fa-envelope"></i> ' . $list['user_email'] . '</p>';
if($list['user_sex'] == 0){
'pro_choice'insiyet = '<div class="user_item_flag"><i class="mdi mdi-gender-male imale imale gendermale gender"></i></div>';
} else if($list['user_sex'] == 1){
'pro_choice'insiyet = '<div class="user_item_flag"><i class="mdi mdi-gender-male imale gendermale gender" title="'.$lang['male'].'"></i></div>';
} else if($list['user_sex'] == 2){
'pro_choice'insiyet = '<div class="user_item_flag"><i class="mdi mdi-gender-female ifemale genderfemale gender" title="'.$lang['female'].'"></i></div>';
} else if($list['user_sex'] == 3){
'pro_choice'insiyet = '<div class="user_item_flag"><i class="mdi mdi-gender-male imale imale gendermale gender"></i></div>';
}
$onay = '<div class="user_item_icon icmute '.$list['user_id'].'" onclick="onayislem('.$list['user_id'].', 1); DivSil(this);"><i class="fa fa-check success"></i></div><div class="user_item_icon icmute '.$list['user_id'].'" onclick="onayislem('.$list['user_id'].', 2); DivSil(this);"><i class="fa fa-close success"></i></div><div class="user_item_icon icmute" onclick="listAction('.$list['user_id'].', \'ban\'); DivSil(this);"><i class="fa fa-ban error"></i></div><div class="user_item_icon icmute" onclick="listAction('.$list['user_id'].', \'delete_account\'); DivSil(this);"><i class="fa fa-trash error"></i></div>';
return '<div data="' . $list['user_id'] . '" class="avtrig user_item offline">
<div data="' . $list['user_id'] . '" class="user_item_avatar get_info"><img class="avav lazy acav" src="' . myAvatar($list['user_tumb']) . '"/> </div>
<div class="user_item_data"><p data="' . $list['user_id'] . '" class="get_info username ' . myColorFont($list) . '">' . $list["user_name"] . '</p>' . $Yetki . '</div>
' . $onay . 'pro_choice'insiyet. '
</div>';
}
© 2023 Quttera Ltd. All rights reserved.