Add files via upload
This commit is contained in:
parent
b97aae2dc1
commit
06f98665a2
7 changed files with 733 additions and 0 deletions
228
hub/online_list.php
Normal file
228
hub/online_list.php
Normal file
|
|
@ -0,0 +1,228 @@
|
||||||
|
<?php
|
||||||
|
require_once("../inc/conx.php");
|
||||||
|
if($logged_in == false) {
|
||||||
|
header("location: /");
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
// if active, display them
|
||||||
|
$musr_q = mysqli_query($conx, "SELECT online_time FROM accounts WHERE lurker_mode='no' ORDER BY username ASC");
|
||||||
|
while($musr_r = mysqli_fetch_assoc($musr_q)) {
|
||||||
|
$mmb_onltime = $musr_r['online_time'];
|
||||||
|
$HUAHHH = time() - $mmb_onltime;
|
||||||
|
$mens = round($HUAHHH / 60);
|
||||||
|
if($mens <= 1 OR $mens <= 2) {
|
||||||
|
$counter++;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
echo "<div class=\"mail_cont\" style=\"border-top-left-radius: 1em; border-top-right-radius: 1em; box-shadow: 0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);border-top: none; font-weight: bold; font-size: 18px;\"><div style=\"font-size:12px;\"><br></div>$counter";
|
||||||
|
if($counter >= 20) {
|
||||||
|
// Emoji+ replacement
|
||||||
|
//$string = " :heart-eyes:";
|
||||||
|
$string = " <img src=\"/img/stickers/ricardo-smile.png\" alt=\"\" style=\"height: 30px; width: auto;\">";
|
||||||
|
}
|
||||||
|
elseif($counter >= 15) {
|
||||||
|
// Emoji+ replacement
|
||||||
|
//$string = " :halo:";
|
||||||
|
$string = " <img src=\"/img/stickers/pepe-weetawd.png\" alt=\"\" style=\"height: 30px; width: auto;\">";
|
||||||
|
}
|
||||||
|
elseif($counter >= 10) {
|
||||||
|
// Emoji+ replacement
|
||||||
|
//$string = " :drool:";
|
||||||
|
$string = " <img src=\"/img/stickers/pepe-mk.png\" alt=\"\" style=\"height: 30px; width: auto;\">";
|
||||||
|
}
|
||||||
|
elseif($counter >= 4) {
|
||||||
|
// Emoji+ replacement
|
||||||
|
//$string = " :smile:";
|
||||||
|
$string = " <img src=\"/img/stickers/pepe-k.png\" alt=\"\" style=\"height: 30px; width: auto;\">";
|
||||||
|
}
|
||||||
|
elseif($counter <= 3) {
|
||||||
|
// Emoji+ replacement
|
||||||
|
$string = " <img src=\"/img/stickers/lock.png\" alt=\"\" style=\"height: 30px; width: auto;\">";
|
||||||
|
//$string = ":sleep:";
|
||||||
|
}
|
||||||
|
include("../inc/replace.php");
|
||||||
|
echo $string;
|
||||||
|
echo "<br> <span onclick=\"moreRecently('recently_active')\" style=\"color: #808080; font-size: 12px;\">[tap to show recently active]</span><div style=\"font-size:12px;\"><br></div></div>";
|
||||||
|
$musr_q = mysqli_query($conx, "SELECT uid,username,perk_levelone,picture,online_time,site_locdesc,site_locurl,who_can_mail,bot,comm_mang,cont_mang,design_police,peacekeeper,sticker,donor,md_verf FROM accounts WHERE lurker_mode='no' ORDER BY username ASC");
|
||||||
|
while($musr_r = mysqli_fetch_assoc($musr_q)) {
|
||||||
|
$mmb_uid = $musr_r['uid'];
|
||||||
|
$mmb_username = $musr_r['username'];
|
||||||
|
$mmb_perk_levelone = $musr_r['perk_levelone'];
|
||||||
|
$mmb_picture = $musr_r['picture'];
|
||||||
|
$mmb_onltime = $musr_r['online_time'];
|
||||||
|
$mmb_locdesc = $musr_r['site_locdesc'];
|
||||||
|
$mmb_locurl = $musr_r['site_locurl'];
|
||||||
|
$mmb_whocan = $musr_r['who_can_mail'];
|
||||||
|
$mmb_bot = $musr_r['bot'];
|
||||||
|
$mmb_comm_mang = $musr_r['comm_mang'];
|
||||||
|
$mmb_cont_mang = $musr_r['cont_mang'];
|
||||||
|
$mmb_design_pol = $musr_r['design_police'];
|
||||||
|
$mmb_peacekpr = $musr_r['peacekeeper'];
|
||||||
|
$mmb_donor = $musr_r['donor'];
|
||||||
|
$mmb_sticker = $musr_r['sticker'];
|
||||||
|
$mmb_verif = $musr_r['md_verf'];
|
||||||
|
if($mmb_verif == 'yes') {
|
||||||
|
$verif_check = "<i style=\"font-size: 14px;\" class=\"fa fa-check-circle\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$verif_check = "";
|
||||||
|
}
|
||||||
|
// ************************ //
|
||||||
|
// *** BLOCKING SYSTEM *** //
|
||||||
|
// ************************ //
|
||||||
|
$blks = mysqli_query($conx, "SELECT blocked_uid FROM blocking WHERE uid='$u_uid' && blocked_uid='$mmb_uid'");
|
||||||
|
$blkc = mysqli_num_rows($blks);
|
||||||
|
if($blkc > 0) {
|
||||||
|
$mmb_uid = "286";
|
||||||
|
}
|
||||||
|
$blks = mysqli_query($conx, "SELECT blocked_uid FROM blocking WHERE blocked_uid='$u_uid' && uid='$mmb_uid'");
|
||||||
|
$blkc = mysqli_num_rows($blks);
|
||||||
|
if($blkc > 0) {
|
||||||
|
$mmb_uid = "286";
|
||||||
|
}
|
||||||
|
// ************************ //
|
||||||
|
// *** BLOCKING SYSTEM *** //
|
||||||
|
// ************************ //
|
||||||
|
//
|
||||||
|
// DATA SAVER
|
||||||
|
if($u_datasaver == 'on' && $mmb_uid != $u_uid) {
|
||||||
|
$mmb_picture = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA8AAAAPCAYAAAA71pVKAAABtklEQVR4AW1TNXgUYRC9HqdvoYW+PT/c3Z0KWvqWLp7drCvuDg3uVNEGh3hyro8ZLGuz31v7n/waW33i9H/oq7SlxmrjCOGBudocI5T5yd/8n9u9fI9QX0GEG0SuEPAbq/j5F/yf2pnnE9OPldT4gQAvzu88D3ON/x/zmP9brP3p6nUvwcgZuHLsCj49/4RrJ67xt8+A+ayL0cvRYFftjRZG7o+Aa+TBCMwNofQK61h83+e6ysCLzhdo1Brg4uejs4+gZJRg+v0YvYx6u3vz1E0Uxgrw1sTnCej7dch+g1EWlzxuGLg5gKh67bxGZ6ITSlb9Jy7PJfNYt9oYGx5DVH0f+I7edQJ6UwLUnMpBo3NjJrG11cLo8Gi0ePA7hPUihJQIKSuzwV3fbNP045X5Ci26gvXMeIbuZA+kjAwlpxTVVco+3zrzTGtbNby79g6lfAnNZhPF2SJeX3mN3o29ENN9LIS6SnWVVfLC0A5jA2mNBOOkAeeMC+mIjPZ0B3cXclYGJT4hLPfvbTbw7G0tq0FIiuhO9HAij7NIqSYJl3n3ttcgdKpoYsb6MtIdKSvtknPSfC//FxxTQV29mEp6AAAAAElFTkSuQmCC";
|
||||||
|
}
|
||||||
|
// DATA SAVER
|
||||||
|
//
|
||||||
|
$usri_q = mysqli_query($conx, "SELECT username_color,text_color FROM user_theme_colors WHERE uid='$mmb_uid' && theme_id='$g_themeid'");
|
||||||
|
while($usri_r = mysqli_fetch_assoc($usri_q)) {
|
||||||
|
$username_color = $usri_r['username_color'];
|
||||||
|
$chat_tcolor = $usri_r['text_color'];
|
||||||
|
}
|
||||||
|
$HUAHHH = time() - $mmb_onltime;
|
||||||
|
$mens = round($HUAHHH / 60);
|
||||||
|
if($mens <= 1) {
|
||||||
|
$cv_activeness = "#00FF00";
|
||||||
|
}
|
||||||
|
elseif($mens <= 2) {
|
||||||
|
$cv_activeness = "#FFA500";
|
||||||
|
}
|
||||||
|
elseif($mens < 5) {
|
||||||
|
$cv_activeness = "#FF0000";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$cv_activeness = "#FF0000";
|
||||||
|
}
|
||||||
|
if($mens <= 1 OR $mens <= 2) {
|
||||||
|
if($mmb_uid != '286') {
|
||||||
|
echo "<div class=\"mail_cont\" style=\"box-shadow: 0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);\">
|
||||||
|
<table style=\"text-align: center; width: 100%;\">
|
||||||
|
<tr>
|
||||||
|
<td style=\"width: 20%;\" onclick=\"window.location='/canvas/$mmb_username';\">
|
||||||
|
<div class=\"mphoto_contain_size\">
|
||||||
|
<div class=\"mphoto_activity_dot\" style=\"background-color: $cv_activeness;\"></div> <img src=\"$mmb_picture\" class=\"list_picture\">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td style=\"width: 50%; text-align: left;\">
|
||||||
|
<span style=\"color: $username_color; font-weight: bold;\" onclick=\"window.location='/canvas/$mmb_username';\">";
|
||||||
|
if($mmb_perk_levelone == 'yes') {
|
||||||
|
echo "<sup style=\"font-size: 10px; color: #ccac00;\">V</sup><sup style=\"font-size: 10px; color: #ffd700;\">I</sup><sup style=\"font-size: 10px; color: #e5c100;\">P</sup> <span style=\"text-decoration: underline;\">$mmb_username</span></span>";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
echo "$mmb_username $verif_check</span>";
|
||||||
|
}
|
||||||
|
if($mmb_sticker != '') {
|
||||||
|
echo " <img src=\"$mmb_sticker\" alt=\"\" style=\"height: 16px;\">";
|
||||||
|
}
|
||||||
|
echo "<br>
|
||||||
|
<span title=\"$mmb_locurl\" onclick=\"window.location='$mmb_locurl';\" style=\"font-size: 12px; color: $username_color;\"><i class=\"fa fa-location-arrow\" aria-hidden=\"true\"></i> $mmb_locdesc</span>";
|
||||||
|
echo "<span style=\"font-size: 8px; color: $username_color;\"> ";
|
||||||
|
# If account is a bot.
|
||||||
|
if($mmb_bot == 'yes') {
|
||||||
|
echo "<i title=\"Bot\" class=\"fa fa-android\" aria-hidden=\"true\"></i> ";
|
||||||
|
}
|
||||||
|
# Display the appropriate badges earned by the user.
|
||||||
|
// Community Manager Badge.
|
||||||
|
if($mmb_comm_mang == 'yes') {
|
||||||
|
echo "<i title=\"Community Manager\" class=\"fa fa-users\" aria-hidden=\"true\"></i> ";
|
||||||
|
}
|
||||||
|
// Account Manager Badge.
|
||||||
|
if($mmb_cont_mang == 'yes') {
|
||||||
|
echo "<i title=\"Content Manager\" class=\"fa fa-shield\" aria-hidden=\"true\"></i> ";
|
||||||
|
}
|
||||||
|
// Design Police Badge.
|
||||||
|
if($mmb_design_pol == 'yes') {
|
||||||
|
echo "<i title=\"Design Police\" class=\"fa fa-paint-brush\" aria-hidden=\"true\"></i> ";
|
||||||
|
}
|
||||||
|
// Peacekeeper Badge.
|
||||||
|
if($mmb_peacekpr == 'yes') {
|
||||||
|
echo "<i title=\"Peacekeeper\" class=\"fa fa-hand-peace-o\" aria-hidden=\"true\"></i> ";
|
||||||
|
}
|
||||||
|
// Donor Badge.
|
||||||
|
if($mmb_donor == 'yes') {
|
||||||
|
echo "<i title=\"Donor\" class=\"fa fa-heartbeat\" aria-hidden=\"true\"></i> </span>";
|
||||||
|
}
|
||||||
|
echo "</td>
|
||||||
|
<td style=\"width: 20%;\">";
|
||||||
|
if($mmb_username != $u_username) {
|
||||||
|
if($mmb_whocan == 'nobody') {
|
||||||
|
echo "<i style=\"color: transparent !important;\" class=\"fa fa-comment\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
if($mmb_whocan == 'friends') {
|
||||||
|
$ff_q = mysqli_query($conx, "SELECT uid_rec FROM friends WHERE uid_req='$u_uid' AND uid_rec='$mmb_uid' AND accepted='yes'");
|
||||||
|
$fr_ct = mysqli_num_rows($ff_q);
|
||||||
|
if($fr_ct != '0') {
|
||||||
|
echo "<i id=\"cuid_$mmb_uid\" style=\"color: $username_color;\" class=\"fa fa-comment\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if($mmb_whocan == 'anyone') {
|
||||||
|
echo "<i id=\"cuid_$mmb_uid\" style=\"color: $username_color;\" class=\"fa fa-comment\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
echo "<i style=\"color: transparent;\" class=\"fa fa-comment\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
echo "</td></tr>
|
||||||
|
</table>
|
||||||
|
</div>";
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$member_count = mysqli_num_rows(mysqli_query($conx, "SELECT username FROM accounts WHERE verified='yes'"));
|
||||||
|
$member_count = number_format($member_count);
|
||||||
|
$lt_mb = mysqli_query($conx, "SELECT username FROM accounts WHERE verified='yes' ORDER BY uid DESC LIMIT 1");
|
||||||
|
$ltr_mb = mysqli_fetch_assoc($lt_mb);
|
||||||
|
$latest_member = $ltr_mb['username'];
|
||||||
|
$rq = mysqli_query($conx, "SELECT category FROM apps WHERE id='13'");
|
||||||
|
$da = mysqli_fetch_array($rq);
|
||||||
|
$r_cnt = $da['category'];
|
||||||
|
$r_cnt = number_format($r_cnt);
|
||||||
|
echo "<div id=\"site_details\" class=\"mail_cont\" style=\"border-bottom-right-radius: 1em; border-bottom-left-radius: 1em; box-shadow: 0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);font-size: 12px; color: #808080;\">
|
||||||
|
<span onclick=\"window.location='/canvas/$latest_member';\" style=\"font-weight: bold;\">$latest_member</span> is our newest member. <br>
|
||||||
|
Our record high of online users is <span style=\"font-weight: bold;\">$r_cnt</span>. <br>
|
||||||
|
We currently have <span style=\"font-weight: bold;\">$member_count</span> registered members.
|
||||||
|
</div>";
|
||||||
|
?>
|
||||||
|
<script>
|
||||||
|
var Msg = document.querySelectorAll("i[id^=cuid_]");
|
||||||
|
[].forEach.call(Msg, function(ms){
|
||||||
|
ms.onclick = function(e){
|
||||||
|
if (confirm("Message?")) {
|
||||||
|
var mso = new XMLHttpRequest();
|
||||||
|
mso.open("GET", "/mail/convo_create.php?u=" + ms.id.match(/([0-9]*)$/)[0], true);
|
||||||
|
mso.onreadystatechange = function(){
|
||||||
|
if (mso.readyState == 4)
|
||||||
|
if(mso.status == 200) {
|
||||||
|
window.location.replace("/mail");
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
alert("error");
|
||||||
|
}
|
||||||
|
};
|
||||||
|
mso.send();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
});
|
||||||
|
</script>
|
||||||
191
hub/recently_active.php
Normal file
191
hub/recently_active.php
Normal file
|
|
@ -0,0 +1,191 @@
|
||||||
|
<?php
|
||||||
|
require_once("../inc/conx.php");
|
||||||
|
if($logged_in == false) {
|
||||||
|
header("location: /");
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
// recently active // recently active
|
||||||
|
// recently active // recently active
|
||||||
|
// recently active // recently active
|
||||||
|
// recently active // recently active
|
||||||
|
// recently active // recently active
|
||||||
|
// recently active // recently active
|
||||||
|
$zmusr_q = mysqli_query($conx, "SELECT online_time FROM accounts ORDER BY username ASC");
|
||||||
|
while($zmusr_r = mysqli_fetch_assoc($zmusr_q)) {
|
||||||
|
$mmb_onltime = $zmusr_r['online_time'];
|
||||||
|
$HUAHHH = time() - $mmb_onltime;
|
||||||
|
$mens = round($HUAHHH / 60);
|
||||||
|
if($mens <= 2880 AND $mens > 6) {
|
||||||
|
$zcounter++;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
echo "<div class=\"mail_cont\" style=\"border-top-left-radius: 1em; border-top-right-radius: 1em; box-shadow: 0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);border-top: none; border-bottom: 1px dotted #ccc; font-weight: bold; font-size: 18px;\"><div style=\"font-size:12px;\"><br></div>$zcounter";
|
||||||
|
if($zcounter >= 20) {
|
||||||
|
// Emoji+ replacement
|
||||||
|
//$string = " :heart-eyes:";
|
||||||
|
$string = " <img src=\"/img/stickers/ricardo-smile.png\" alt=\"\" style=\"height: 30px; width: auto;\">";
|
||||||
|
}
|
||||||
|
elseif($zcounter >= 15) {
|
||||||
|
// Emoji+ replacement
|
||||||
|
//$string = " :halo:";
|
||||||
|
$string = " <img src=\"/img/stickers/pepe-weetawd.png\" alt=\"\" style=\"height: 30px; width: auto;\">";
|
||||||
|
}
|
||||||
|
elseif($zcounter >= 10) {
|
||||||
|
// Emoji+ replacement
|
||||||
|
//$string = " :drool:";
|
||||||
|
$string = " <img src=\"/img/stickers/pepe-mk.png\" alt=\"\" style=\"height: 30px; width: auto;\">";
|
||||||
|
}
|
||||||
|
elseif($zcounter >= 4) {
|
||||||
|
// Emoji+ replacement
|
||||||
|
//$string = " :smile:";
|
||||||
|
$string = " <img src=\"/img/stickers/pepe-k.png\" alt=\"\" style=\"height: 30px; width: auto;\">";
|
||||||
|
}
|
||||||
|
elseif($zcounter <= 3) {
|
||||||
|
// Emoji+ replacement
|
||||||
|
//$string = " :sleep:";
|
||||||
|
$string = " <img src=\"/img/stickers/lock.png\" alt=\"\" style=\"height: 30px; width: auto;\">";
|
||||||
|
}
|
||||||
|
include("../inc/replace.php");
|
||||||
|
echo $string;
|
||||||
|
echo "<br> <span style=\"color: #808080; font-size: 12px; font-weight: none;\" onclick=\"moreRecently('recently_active')\">[tap to hide]</span><div style=\"font-size:12px;\"><br></div>";
|
||||||
|
echo "</div>";
|
||||||
|
$zmusr_q = mysqli_query($conx, "SELECT uid,username,picture,online_time,site_locdesc,site_locurl,who_can_mail,bot,comm_mang,cont_mang,design_police,peacekeeper,sticker,donor,md_verf FROM accounts ORDER BY username ASC");
|
||||||
|
while($zmusr_r = mysqli_fetch_assoc($zmusr_q)) {
|
||||||
|
$mmb_uid = $zmusr_r['uid'];
|
||||||
|
$mmb_username = $zmusr_r['username'];
|
||||||
|
$mmb_picture = $zmusr_r['picture'];
|
||||||
|
$mmb_onltime = $zmusr_r['online_time'];
|
||||||
|
$mmb_locdesc = $zmusr_r['site_locdesc'];
|
||||||
|
$mmb_locurl = $zmusr_r['site_locurl'];
|
||||||
|
$mmb_whocan = $zmusr_r['who_can_mail'];
|
||||||
|
$mmb_bot = $zmusr_r['bot'];
|
||||||
|
$mmb_comm_mang = $zmusr_r['comm_mang'];
|
||||||
|
$mmb_cont_mang = $zmusr_r['cont_mang'];
|
||||||
|
$mmb_design_pol = $zmusr_r['design_police'];
|
||||||
|
$mmb_peacekpr = $zmusr_r['peacekeeper'];
|
||||||
|
$mmb_donor = $zmusr_r['donor'];
|
||||||
|
$mmb_sticker = $zmusr_r['sticker'];
|
||||||
|
$mmb_verif = $zmusr_r['md_verf'];
|
||||||
|
if($mmb_verif == 'yes') {
|
||||||
|
$verif_check = "<i style=\"font-size: 14px;\" class=\"fa fa-check-circle\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$verif_check = "";
|
||||||
|
}
|
||||||
|
// ************************ //
|
||||||
|
// *** BLOCKING SYSTEM *** //
|
||||||
|
// ************************ //
|
||||||
|
$blks = mysqli_query($conx, "SELECT blocked_uid FROM blocking WHERE uid='$u_uid' && blocked_uid='$mmb_uid'");
|
||||||
|
$blkc = mysqli_num_rows($blks);
|
||||||
|
if($blkc > 0) {
|
||||||
|
$mmb_uid = "286";
|
||||||
|
}
|
||||||
|
$blks = mysqli_query($conx, "SELECT blocked_uid FROM blocking WHERE blocked_uid='$u_uid' && uid='$mmb_uid'");
|
||||||
|
$blkc = mysqli_num_rows($blks);
|
||||||
|
if($blkc > 0) {
|
||||||
|
$mmb_uid = "286";
|
||||||
|
}
|
||||||
|
// ************************ //
|
||||||
|
// *** BLOCKING SYSTEM *** //
|
||||||
|
// ************************ //
|
||||||
|
//
|
||||||
|
// DATA SAVER
|
||||||
|
if($u_datasaver == 'on' && $mmb_uid != $u_uid) {
|
||||||
|
$mmb_picture = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA8AAAAPCAYAAAA71pVKAAABtklEQVR4AW1TNXgUYRC9HqdvoYW+PT/c3Z0KWvqWLp7drCvuDg3uVNEGh3hyro8ZLGuz31v7n/waW33i9H/oq7SlxmrjCOGBudocI5T5yd/8n9u9fI9QX0GEG0SuEPAbq/j5F/yf2pnnE9OPldT4gQAvzu88D3ON/x/zmP9brP3p6nUvwcgZuHLsCj49/4RrJ67xt8+A+ayL0cvRYFftjRZG7o+Aa+TBCMwNofQK61h83+e6ysCLzhdo1Brg4uejs4+gZJRg+v0YvYx6u3vz1E0Uxgrw1sTnCej7dch+g1EWlzxuGLg5gKh67bxGZ6ITSlb9Jy7PJfNYt9oYGx5DVH0f+I7edQJ6UwLUnMpBo3NjJrG11cLo8Gi0ePA7hPUihJQIKSuzwV3fbNP045X5Ci26gvXMeIbuZA+kjAwlpxTVVco+3zrzTGtbNby79g6lfAnNZhPF2SJeX3mN3o29ENN9LIS6SnWVVfLC0A5jA2mNBOOkAeeMC+mIjPZ0B3cXclYGJT4hLPfvbTbw7G0tq0FIiuhO9HAij7NIqSYJl3n3ttcgdKpoYsb6MtIdKSvtknPSfC//FxxTQV29mEp6AAAAAElFTkSuQmCC";
|
||||||
|
}
|
||||||
|
// DATA SAVER
|
||||||
|
//
|
||||||
|
$usri_q = mysqli_query($conx, "SELECT username_color,text_color FROM user_theme_colors WHERE uid='$mmb_uid' && theme_id='$g_themeid'");
|
||||||
|
while($usri_r = mysqli_fetch_assoc($usri_q)) {
|
||||||
|
$username_color = $usri_r['username_color'];
|
||||||
|
$chat_tcolor = $usri_r['text_color'];
|
||||||
|
}
|
||||||
|
$HUAHHH = time() - $mmb_onltime;
|
||||||
|
$mens = round($HUAHHH / 60);
|
||||||
|
/*if($mens <= 1) {
|
||||||
|
$cv_activeness = "#00FF00";
|
||||||
|
}
|
||||||
|
elseif($mens <= 2) {
|
||||||
|
$cv_activeness = "#FFA500";
|
||||||
|
}
|
||||||
|
elseif($mens < 5) {
|
||||||
|
$cv_activeness = "#FF0000";
|
||||||
|
}
|
||||||
|
else {*/
|
||||||
|
$cv_activeness = "#808080";
|
||||||
|
//}
|
||||||
|
if($mens <= 2880 AND $mens > 6) {
|
||||||
|
if($mmb_uid != '286') {
|
||||||
|
echo "<div class=\"mail_cont\" style=\"box-shadow: 0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);border-top: none; border-bottom: 1px dotted #ccc;\">
|
||||||
|
<table style=\"text-align: center; width: 100%;\">
|
||||||
|
<tr>
|
||||||
|
<td style=\"width: 20%;\" onclick=\"window.location='/canvas/$mmb_username';\">
|
||||||
|
<div class=\"mphoto_contain_size\">
|
||||||
|
<div class=\"mphoto_activity_dot\" style=\"background-color: $cv_activeness;\"></div> <img src=\"$mmb_picture\" class=\"list_picture\">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td style=\"width: 50%; text-align: left;\">
|
||||||
|
<span style=\"color: $username_color; font-weight: bold;\" onclick=\"window.location='/canvas/$mmb_username';\">$mmb_username $verif_check</span>";
|
||||||
|
if($mmb_sticker != '') {
|
||||||
|
echo " <img src=\"$mmb_sticker\" alt=\"\" style=\"height: 16px;\">";
|
||||||
|
}
|
||||||
|
echo "<br>
|
||||||
|
<span title=\"$mmb_locurl\" style=\"font-size: 12px; color: $username_color;\"><i class=\"fa fa-clock-o\" aria-hidden=\"true\"></i> active "; echo timeago($mmb_onltime); echo " ago</span>";
|
||||||
|
echo "<span style=\"font-size: 8px; color: $username_color;\"> ";
|
||||||
|
# If account is a bot.
|
||||||
|
if($mmb_bot == 'yes') {
|
||||||
|
echo "<i title=\"Bot\" class=\"fa fa-android\" aria-hidden=\"true\"></i> ";
|
||||||
|
}
|
||||||
|
# Display the appropriate badges earned by the user.
|
||||||
|
// Community Manager Badge.
|
||||||
|
if($mmb_comm_mang == 'yes') {
|
||||||
|
echo "<i title=\"Community Manager\" class=\"fa fa-users\" aria-hidden=\"true\"></i> ";
|
||||||
|
}
|
||||||
|
// Account Manager Badge.
|
||||||
|
if($mmb_cont_mang == 'yes') {
|
||||||
|
echo "<i title=\"Content Manager\" class=\"fa fa-shield\" aria-hidden=\"true\"></i> ";
|
||||||
|
}
|
||||||
|
// Design Police Badge.
|
||||||
|
if($mmb_design_pol == 'yes') {
|
||||||
|
echo "<i title=\"Design Police\" class=\"fa fa-paint-brush\" aria-hidden=\"true\"></i> ";
|
||||||
|
}
|
||||||
|
// Peacekeeper Badge.
|
||||||
|
if($mmb_peacekpr == 'yes') {
|
||||||
|
echo "<i title=\"Peacekeeper\" class=\"fa fa-hand-peace-o\" aria-hidden=\"true\"></i> ";
|
||||||
|
}
|
||||||
|
// Donor Badge.
|
||||||
|
if($mmb_donor == 'yes') {
|
||||||
|
echo "<i title=\"Donor\" class=\"fa fa-heartbeat\" aria-hidden=\"true\"></i> </span>";
|
||||||
|
}
|
||||||
|
echo "</td>
|
||||||
|
<td style=\"width: 20%;\">";
|
||||||
|
if($mmb_username != $u_username) {
|
||||||
|
if($mmb_whocan == 'nobody') {
|
||||||
|
echo "<i style=\"color: transparent !important;\" class=\"fa fa-comment\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
if($mmb_whocan == 'friends') {
|
||||||
|
$ff_q = mysqli_query($conx, "SELECT uid_rec FROM friends WHERE uid_req='$u_uid' AND uid_rec='$mmb_uid' AND accepted='yes'");
|
||||||
|
$fr_ct = mysqli_num_rows($ff_q);
|
||||||
|
if($fr_ct != '0') {
|
||||||
|
echo "<i id=\"cuid_$mmb_uid\" style=\"color: $username_color;\" class=\"fa fa-comment\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if($mmb_whocan == 'anyone') {
|
||||||
|
echo "<i id=\"cuid_$mmb_uid\" style=\"color: $username_color;\" class=\"fa fa-comment\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
echo "<i style=\"color: transparent;\" class=\"fa fa-comment\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
echo "</td></tr>
|
||||||
|
</table>
|
||||||
|
</div>";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
<div class="mail_cont" style="border-bottom-left-radius: 1em; border-bottom-right-radius: 1em; box-shadow: 0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);border-top: none; border-bottom: 1px dotted #ccc; font-weight: bold; font-size: 18px;">
|
||||||
|
|
||||||
|
</div> <br>
|
||||||
150
hub/shout.php
Normal file
150
hub/shout.php
Normal file
|
|
@ -0,0 +1,150 @@
|
||||||
|
<?php
|
||||||
|
require_once("../inc/conx.php");
|
||||||
|
if($logged_in == false) {
|
||||||
|
header("location: /");
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
$shout_q = mysqli_query($conx, "SELECT * FROM shouts ORDER BY id DESC LIMIT 1");
|
||||||
|
while($shout_r = mysqli_fetch_assoc($shout_q)) {
|
||||||
|
$shout_id = $shout_r['id'];
|
||||||
|
$shout_uid = $shout_r['uid'];
|
||||||
|
$shout_text = $shout_r['texts'];
|
||||||
|
$shout_timeleft = $shout_r['time_left'];
|
||||||
|
$shout_cost = $shout_r['mdf_cost'];
|
||||||
|
$shout_tstamp = $shout_r['tstamp'];
|
||||||
|
function release_time($session_time) {
|
||||||
|
$time_difference = $session_time - time();
|
||||||
|
$seconds = $time_difference;
|
||||||
|
$minutes = round($time_difference/60);
|
||||||
|
$hours = round($time_difference/3600);
|
||||||
|
$days = round($time_difference/86400);
|
||||||
|
$weeks = round($time_difference/604800);
|
||||||
|
$months = round($time_difference/2419200);
|
||||||
|
$years = round($time_difference/29030400);
|
||||||
|
$s_ago = "s"; $m_ago = "m"; $h_ago = "h"; $w_ago = "w"; $d_ago = "d";
|
||||||
|
if($seconds <= 59) { echo "$seconds$s_ago"; }
|
||||||
|
else if($minutes <= 59) {
|
||||||
|
if($minutes == 1) { echo "1$m_ago"; }
|
||||||
|
else { echo "$minutes$m_ago"; }
|
||||||
|
}
|
||||||
|
else if($hours <= 23) {
|
||||||
|
if($hours == 1) { echo "1$h_ago"; }
|
||||||
|
else { echo "$hours$h_ago"; }
|
||||||
|
}
|
||||||
|
else if($days <= 6) {
|
||||||
|
if($days == 1) { echo "1$d_ago"; }
|
||||||
|
else { echo "$days$d_ago"; }
|
||||||
|
}
|
||||||
|
else if($weeks > 0) {
|
||||||
|
if($weeks == 1) { echo "1$w_ago"; }
|
||||||
|
else { echo "$weeks$w_ago"; }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if($shout_timeleft >= $tstamp) {
|
||||||
|
$shout_yn = "yes";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$shout_yn = "no";
|
||||||
|
}
|
||||||
|
$shouuut_q = mysqli_query($conx, "SELECT username,md_verf FROM accounts WHERE uid='$shout_uid'");
|
||||||
|
while($shouuut_r = mysqli_fetch_assoc($shouuut_q)) {
|
||||||
|
$shout_username = $shouuut_r['username'];
|
||||||
|
$shout_verf = $shouuut_r['md_verf'];
|
||||||
|
if($shout_verf == 'yes') {
|
||||||
|
$verif_check = "<i style=\"\" style=\"color: #4c4c4c;\" class=\"fa fa-check-circle\" aria-hidden=\"true\"></i>";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$verif_check = "";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$usrrrrri_q = mysqli_query($conx, "SELECT username_color,text_color FROM user_theme_colors WHERE uid='$shout_uid' && theme_id='$g_themeid'");
|
||||||
|
while($usrrrri_r = mysqli_fetch_assoc($usrrrrri_q)) {
|
||||||
|
$shoutusername_color = $usrrrri_r['username_color'];
|
||||||
|
$shoutchat_tcolor = $usrrrri_r['text_color'];
|
||||||
|
}
|
||||||
|
$string = $shout_text;
|
||||||
|
include("../inc/replace.php");
|
||||||
|
if($shout_yn == "no") {
|
||||||
|
echo "
|
||||||
|
<div onclick=\"writePost();fpostb.focus();\" style=\"box-shadow: 0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);width: 60%; max-width: 300px; background-color: #4DA64D; font-family: 'Dosis', sans-serif; padding: 8px; border-radius: 8em; color: #fff;\">
|
||||||
|
<table style=\"font-weight: bold; text-align: center;\">
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
There aren't any shouts right now.
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Tap to send a shout.
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<br>";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$did_you_like = mysqli_num_rows($slcq = mysqli_query($conx, "SELECT id FROM shout_likedis WHERE shout_id='$shout_id' && likedis='like' && uid='$u_uid'"));
|
||||||
|
if($did_you_like >= '1') {
|
||||||
|
$like_css = "border: 1px solid $shoutusername_color; background-color: $shoutchat_tcolor;";
|
||||||
|
$like_font = "color: $shoutusername_color;";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$like_css = "border: 1px solid $shoutchat_tcolor; background-color: $shoutusername_color;";
|
||||||
|
$like_font = "color: $shoutchat_tcolor;";
|
||||||
|
}
|
||||||
|
$did_you_dislike = mysqli_num_rows($slcq = mysqli_query($conx, "SELECT id FROM shout_likedis WHERE shout_id='$shout_id' && likedis='dislike' && uid='$u_uid'"));
|
||||||
|
if($did_you_dislike >= '1') {
|
||||||
|
$dislike_css = "border: 1px solid $shoutusername_color; background-color: $shoutchat_tcolor;";
|
||||||
|
$dislike_font = "color: $shoutusername_color;";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$dislike_css = "border: 1px solid $shoutchat_tcolor; background-color: $shoutusername_color;";
|
||||||
|
$dislike_font = "color: $shoutchat_tcolor;";
|
||||||
|
}
|
||||||
|
echo "
|
||||||
|
<div class=\"shout_div_contain\">
|
||||||
|
<div onclick=\"shoutLikeDis('$shout_id','like');\" class=\"shout_like\" style=\"$like_css\"><i class=\"fa fa-thumbs-up\" style=\"$like_font\"></i></div>
|
||||||
|
<div onclick=\"shoutLikeDis('$shout_id','dislike');\" class=\"shout_dislike\" style=\"$dislike_css\"><i class=\"fa fa-thumbs-down\" style=\"$dislike_font\"></i></div>
|
||||||
|
<div style=\"box-shadow: 0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);background-color: $shoutusername_color; font-family: 'Dosis', sans-serif; padding: 8px; border-radius: 1em; color: $shoutchat_tcolor;\">
|
||||||
|
<table style=\"text-align: center;\">
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<i class=\"fa fa-bullhorn\"></i> <i class=\"fa fa-bullhorn\"></i> <span style=\"font-size: 12px;\">"; echo release_time($shout_timeleft); echo " left</span>"; echo" <i class=\"fa fa-bullhorn\"></i> <i class=\"fa fa-bullhorn\"></i>
|
||||||
|
<br>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<span style=\"font-size: 18px; font-weight: bold;\">$string</span> <br> <span style=\"font-size: 12px;\"><b>$verif_check $shout_username</b></span> <span style=\"font-size: 11px;\">
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div></div>
|
||||||
|
<div id=\"shout_likedis\" style=\"padding-top: 8px; font-family: 'Dosis', sans-serif; color: #808080; font-size: 12px;\">";
|
||||||
|
$like_cnt = mysqli_num_rows($slcq = mysqli_query($conx, "SELECT id FROM shout_likedis WHERE shout_id='$shout_id' && likedis='like'"));
|
||||||
|
$dislike_cnt = mysqli_num_rows($slcq = mysqli_query($conx, "SELECT id FROM shout_likedis WHERE shout_id='$shout_id' && likedis='dislike'"));
|
||||||
|
if($like_cnt == '0') {
|
||||||
|
$like_likes = "likes";
|
||||||
|
}
|
||||||
|
elseif($like_cnt == '1') {
|
||||||
|
$like_likes = "like";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$like_likes = "likes";
|
||||||
|
}
|
||||||
|
if($dislike_cnt == '0') {
|
||||||
|
$dislike_dislikes = "dislikes";
|
||||||
|
}
|
||||||
|
elseif($dislike_cnt == '1') {
|
||||||
|
$dislike_dislikes = "dislike";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$dislike_dislikes = "dislikes";
|
||||||
|
}
|
||||||
|
echo "$like_cnt $like_likes, $dislike_cnt $dislike_dislikes";
|
||||||
|
echo "</div>
|
||||||
|
<br>";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
?>
|
||||||
40
hub/shout_likedis.php
Normal file
40
hub/shout_likedis.php
Normal file
|
|
@ -0,0 +1,40 @@
|
||||||
|
<?php
|
||||||
|
require_once("../inc/conx.php");
|
||||||
|
if($logged_in == false) {
|
||||||
|
header("location: /");
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
$post_token = mysqli_real_escape_string($conx, htmlentities($_POST['token']));
|
||||||
|
$post_id = mysqli_real_escape_string($conx, htmlentities($_POST['id']));
|
||||||
|
$post_likedis = mysqli_real_escape_string($conx, htmlentities($_POST['likedis']));
|
||||||
|
|
||||||
|
$did_you_like = mysqli_num_rows($slcq = mysqli_query($conx, "SELECT id FROM shout_likedis WHERE shout_id='$post_id' && likedis='like' && uid='$u_uid'"));
|
||||||
|
$did_you_dislike = mysqli_num_rows($slcq = mysqli_query($conx, "SELECT id FROM shout_likedis WHERE shout_id='$post_id' && likedis='dislike' && uid='$u_uid'"));
|
||||||
|
|
||||||
|
if($post_token == $u_token) {
|
||||||
|
if($post_likedis == 'like') {
|
||||||
|
if($did_you_like >= '1') {
|
||||||
|
mysqli_query($conx, "DELETE FROM shout_likedis WHERE uid='$u_uid' && shout_id='$post_id' && likedis='like'");
|
||||||
|
}
|
||||||
|
elseif($did_you_dislike >= '1') {
|
||||||
|
mysqli_query($conx, "DELETE FROM shout_likedis WHERE uid='$u_uid' && shout_id='$post_id' && likedis='dislike'");
|
||||||
|
mysqli_query($conx, "INSERT INTO shout_likedis (shout_id, uid, likedis) VALUES ('$post_id', '$u_uid', '$post_likedis')");
|
||||||
|
}
|
||||||
|
elseif($did_you_dislike == '0') {
|
||||||
|
mysqli_query($conx, "INSERT INTO shout_likedis (shout_id, uid, likedis) VALUES ('$post_id', '$u_uid', '$post_likedis')");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if($post_likedis == 'dislike') {
|
||||||
|
if($did_you_dislike >= '1') {
|
||||||
|
mysqli_query($conx, "DELETE FROM shout_likedis WHERE uid='$u_uid' && shout_id='$post_id' && likedis='dislike'");
|
||||||
|
}
|
||||||
|
elseif($did_you_like >= '1') {
|
||||||
|
mysqli_query($conx, "DELETE FROM shout_likedis WHERE uid='$u_uid' && shout_id='$post_id' && likedis='like'");
|
||||||
|
mysqli_query($conx, "INSERT INTO shout_likedis (shout_id, uid, likedis) VALUES ('$post_id', '$u_uid', '$post_likedis')");
|
||||||
|
}
|
||||||
|
elseif($did_you_like == '0') {
|
||||||
|
mysqli_query($conx, "INSERT INTO shout_likedis (shout_id, uid, likedis) VALUES ('$post_id', '$u_uid', '$post_likedis')");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
29
hub/shout_stats.php
Normal file
29
hub/shout_stats.php
Normal file
|
|
@ -0,0 +1,29 @@
|
||||||
|
<?php
|
||||||
|
require_once("../inc/conx.php");
|
||||||
|
if($logged_in == false) {
|
||||||
|
header("location: /");
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
$get_shoutID = safe($_GET['id']);
|
||||||
|
$like_cnt = mysqli_num_rows($slcq = mysqli_query($conx, "SELECT id FROM shout_likedis WHERE shout_id='$get_shoutID' && likedis='like'"));
|
||||||
|
$dislike_cnt = mysqli_num_rows($slcq = mysqli_query($conx, "SELECT id FROM shout_likedis WHERE shout_id='$get_shoutID' && likedis='dislike'"));
|
||||||
|
if($like_cnt == '0') {
|
||||||
|
$like_likes = "likes";
|
||||||
|
}
|
||||||
|
elseif($like_cnt == '1') {
|
||||||
|
$like_likes = "like";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$like_likes = "likes";
|
||||||
|
}
|
||||||
|
if($dislike_cnt == '0') {
|
||||||
|
$dislike_dislikes = "dislikes";
|
||||||
|
}
|
||||||
|
elseif($dislike_cnt == '1') {
|
||||||
|
$dislike_dislikes = "dislike";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$dislike_dislikes = "dislikes";
|
||||||
|
}
|
||||||
|
echo "$like_cnt $like_likes, $dislike_cnt $dislike_dislikes";
|
||||||
|
?>
|
||||||
73
hub/shoutit.php
Normal file
73
hub/shoutit.php
Normal file
|
|
@ -0,0 +1,73 @@
|
||||||
|
<?php
|
||||||
|
require_once("../inc/conx.php");
|
||||||
|
if($logged_in == false) {
|
||||||
|
header("location: /");
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
$text = mysqli_real_escape_string($conx, htmlentities($_POST['body']));
|
||||||
|
$shout_time_picked = mysqli_real_escape_string($conx, htmlentities($_POST['timeslot']));
|
||||||
|
$shout_q = mysqli_query($conx, "SELECT * FROM shouts ORDER BY id DESC LIMIT 1");
|
||||||
|
while($shout_r = mysqli_fetch_assoc($shout_q)) {
|
||||||
|
$shout_uid = $shout_r['uid'];
|
||||||
|
$shout_text = $shout_r['texts'];
|
||||||
|
$shout_timeleft = $shout_r['time_left'];
|
||||||
|
$shout_cost = $shout_r['mdf_cost'];
|
||||||
|
$shout_tstamp = $shout_r['tstamp'];
|
||||||
|
if($shout_timeleft >= $tstamp) {
|
||||||
|
$shout_yn = "yes";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$shout_yn = "no";
|
||||||
|
}
|
||||||
|
if (strlen($text)<80) {
|
||||||
|
$shout_goodboi = "yes";
|
||||||
|
}
|
||||||
|
|
||||||
|
// shout times and fees
|
||||||
|
// shout times and fees
|
||||||
|
// shout times and fees
|
||||||
|
if($shout_time_picked == '1') {
|
||||||
|
$shout_time_cost = "1000";
|
||||||
|
$cost_mdf = "1,000";
|
||||||
|
$time_left = $tstamp + 3600;
|
||||||
|
}
|
||||||
|
elseif($shout_time_picked == '2') {
|
||||||
|
$shout_time_cost = "2000";
|
||||||
|
$cost_mdf = "2,000";
|
||||||
|
$time_left = $tstamp + 7200;
|
||||||
|
}
|
||||||
|
elseif($shout_time_picked == '3') {
|
||||||
|
$shout_time_cost = "3000";
|
||||||
|
$cost_mdf = "3,000";
|
||||||
|
$time_left = $tstamp + 10800;
|
||||||
|
}
|
||||||
|
elseif($shout_time_picked == '4') {
|
||||||
|
$shout_time_cost = "4000";
|
||||||
|
$cost_mdf = "4,000";
|
||||||
|
$time_left = $tstamp + 14400;
|
||||||
|
}
|
||||||
|
elseif($shout_time_picked == '5') {
|
||||||
|
$shout_time_cost = "5000";
|
||||||
|
$cost_mdf = "5,000";
|
||||||
|
$time_left = $tstamp + 18000;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$shout_time_cost = "1000";
|
||||||
|
$cost_mdf = "1,000";
|
||||||
|
$time_left = $tstamp + 3600;
|
||||||
|
}
|
||||||
|
// shout times and fees
|
||||||
|
// shout times and fees
|
||||||
|
// shout times and fees
|
||||||
|
if($u_funds >= $shout_time_cost && $shout_yn == 'no' && $shout_goodboi == 'yes') {
|
||||||
|
mysqli_query($conx, "INSERT INTO shouts (uid, texts, tstamp, time_left, mdf_cost) VALUES ('$u_uid','$text','$tstamp','$time_left','$cost_mdf')");
|
||||||
|
mysqli_query($conx, "UPDATE account_figures SET activeness='$f_activeness'+.08 WHERE uid='$u_uid'");
|
||||||
|
mysqli_query($conx, "UPDATE accounts SET funds='$u_funds'-$shout_time_cost WHERE uid='$u_uid'");
|
||||||
|
header("location: /hub");
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
22
hub/theme.php
Normal file
22
hub/theme.php
Normal file
|
|
@ -0,0 +1,22 @@
|
||||||
|
<?php
|
||||||
|
require_once("../inc/conx.php");
|
||||||
|
$gtoken = safe($_GET['t']);
|
||||||
|
$gid = safe($_GET['i']);
|
||||||
|
if($gtoken == $u_token && $logged_in == true && $gid) {
|
||||||
|
if($gid == 'droplets') {
|
||||||
|
mysqli_query($conx, "UPDATE accounts SET hub_theme='droplets' WHERE uid='$u_uid'");
|
||||||
|
}
|
||||||
|
elseif($gid == 'stars') {
|
||||||
|
mysqli_query($conx, "UPDATE accounts SET hub_theme='stars' WHERE uid='$u_uid'");
|
||||||
|
}
|
||||||
|
elseif($gid == 'galaxy') {
|
||||||
|
mysqli_query($conx, "UPDATE accounts SET hub_theme='galaxy' WHERE uid='$u_uid'");
|
||||||
|
}
|
||||||
|
header("location: /hub");
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
header("location: /");
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
?>
|
||||||
Loading…
Add table
Add a link
Reference in a new issue