Menu
Forums
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Trending
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
Upgrades
Log in
Register
What's new
Search
Search
Search titles only
By:
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Server Development
Habbo Retros
Habbo Q&A
#SOLVED Client Stock At 76 Precent #PLUSEMU
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="LeZack" data-source="post: 393181" data-attributes="member: 61455"><p>[USER=73082]@Etrion[/USER] </p><p><?php</p><p>// User gets checked if logged on in class.html.php</p><p>$uid = $_SESSION['user']['id'];</p><p>$conn = $db->PDO();</p><p>// Check for recent boxes opened</p><p>$stmt = $conn->pdo->prepare("SELECT `item_id` FROM `cms_box_opened` WHERE `user_id` = :uid AND `received` = 0");</p><p>$stmt->bindParam(':uid', $uid, $db->PARAM_INT);</p><p>$stmt->execute();</p><p>if($stmt->rowCount() > 0) {</p><p> foreach($stmt as $box) {</p><p> $users->giveUserItem($uid, $box['item_id']);</p><p> }</p><p> $stmt = $conn->pdo->prepare("UPDATE `cms_box_opened` SET `received` = 1 WHERE `user_id` = :uid");</p><p> $stmt->bindParam(':uid', $uid, $db->PARAM_INT);</p><p> $stmt->execute();</p><p>}</p><p></p><p>// Check for recent purchases of packages</p><p>$stmt = $conn->pdo->prepare("SELECT `id` FROM `cms_packages_bought` WHERE `user_id` = :uid AND `itemsGiven` = 0 LIMIT 1");</p><p>$stmt->bindParam(':uid', $uid, $db->PARAM_INT);</p><p>$stmt->execute();</p><p>if($stmt->rowCount() > 0) {</p><p> $pid = $stmt->fetchColumn();</p><p> $p = $admin->packageDecode($pid);</p><p> // Start Badge SQL</p><p> $item_id = $p['item_id'];</p><p> $bid = $p['badge_id'];</p><p> $pCredits = ($users->getUserInfo($uid, 'credits') + $p['credits']);</p><p> $pDuckets = ($users->getUserInfo($uid, 'activity_points') + $p['duckets']);</p><p> if(!$users->hasBadge($uid, $bid)) {</p><p> // User doesn't have this badge</p><p> $users->giveUserBadge($uid, $bid);</p><p> }</p><p> // End Badge SQL</p><p> // Start Item SQL</p><p> // Check if package includes more than 1 item</p><p> $number = substr($p['item_name'], 0, 1);</p><p> if(is_numeric($number)) {</p><p> //$number equals amount of items to be given by first character in item_name..</p><p> for($i = 0; $i < $number; $i++) {</p><p> $users->giveUserItem($uid, $item_id);</p><p> }</p><p> } else {</p><p> // Give user 1 item</p><p> $users->giveUserItem($uid, $item_id);</p><p> }</p><p> // End Item SQL</p><p> // Give user amount of credits and duckets</p><p> $users->updateUser($uid, 'credits', $pCredits);</p><p> $users->updateUser($uid, 'activity_points', $pDuckets);</p><p></p><p> $stmt = $conn->pdo->prepare("UPDATE `cms_packages_bought` SET `itemsGiven` = 1 WHERE `user_id` = :uid AND `id` = <img src="/styles/default/xenforo/smilies/emojione/tongue.png" class="smilie" loading="lazy" alt=":p" title="Stick Out Tongue :p" data-shortname=":p" />id LIMIT 1");</p><p> $stmt->bindParam(':uid', $uid, $db->PARAM_INT);</p><p> $stmt->bindParam('<img src="/styles/default/xenforo/smilies/emojione/tongue.png" class="smilie" loading="lazy" alt=":p" title="Stick Out Tongue :p" data-shortname=":p" />id', $pid, $db->PARAM_INT);</p><p> $stmt->execute();</p><p>}</p><p></p><p>$conn = null;</p><p>?></p><p><!DOCTYPE html></p><p><html lang="da"></p><p> <head></p><p> <meta http-equiv="content-type" content="text/html; charset=utf-8"></p><p> <title>{hotelName}: Hotel</title></p><p> {favicons}</p><p> <link rel="stylesheet" href="static/css/client.css" type="text/css"></p><p> <link href="{hotelurl}/static/css/modal.min.css" rel="stylesheet" /></p><p> <link href="{hotelurl}/static/css/bootstrap.min.css" rel="stylesheet" /></p><p> <link href="{hotelurl}/static/css/habbo-theme.css" rel="stylesheet" /></p><p> <link href="{hotelurl}/static/css/newhabbo.css" rel="stylesheet" /></p><p> <link href="//fonts.googleapis.com/css?family=Ubuntu:400,300,700" rel="stylesheet" type="text/css" /></p><p> <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script></p><p> <script type="text/javascript" src="{hotelurl}/static/js/ajax/swiffy-v2.3.js"></script></p><p></p><p> <script type="text/javascript"></p><p> var BaseUrl = "<a href="https://worldmotel.nl/swfs/gordon/PRODUCTION-201601012205-226667486" target="_blank">https://worldmotel.nl/swfs/gordon/PRODUCTION-201601012205-226667486</a>";</p><p> var flashvars = {</p><p> "client.allow.cross.domain" : "1",</p><p> "client.notify.cross.domain" : "0",</p><p> "connection.info.host" : "EMPTY",</p><p> "connection.info.port" : "30000",</p><p> "site.url" : "<a href="https://worldmotel.nl" target="_blank">https://worldmotel.nl</a>",</p><p> "url.prefix" : "<a href="https://worldmotel.nl" target="_blank">https://worldmotel.nl</a>",</p><p> "client.reload.url" : "{hotelurl}/client",</p><p> "client.fatal.error.url" : "{hotelurl}/me",</p><p> "client.connection.failed.url" : "{hotelurl}/me",</p><p> "external.variables.txt" : "<a href="https://worldmotel.nl/swfs/gamedata/external_variables.txt" target="_blank">https://worldmotel.nl/swfs/gamedata/external_variables.txt</a>",</p><p> "external.texts.txt" : "<a href="https://worldmotel.nl/swfs/gamedata/external_flash_texts.txt" target="_blank">https://worldmotel.nl/swfs/gamedata/external_flash_texts.txt</a>",</p><p> "external.override.texts.txt" : "<a href="https://worldmotel.nl/swfs/gamedata/override/external_flash_override_texts.txt" target="_blank">https://worldmotel.nl/swfs/gamedata/override/external_flash_override_texts.txt</a>",</p><p> "external.override.variables.txt" : "<a href="https://worldmotel.nl/swfs/gamedata/override/external_override_variables.txt" target="_blank">https://worldmotel.nl/swfs/gamedata/override/external_override_variables.txt</a>",</p><p> "external.figurepartlist.txt" : "<a href="https://worldmotel.nl/swfs/gamedata/figuredata.xml" target="_blank">https://worldmotel.nl/swfs/gamedata/figuredata.xml</a>", </p><p> "productdata.load.url" : "<a href="https://worldmotel.nl/swfs/gamedata/productdata.txt" target="_blank">https://worldmotel.nl/swfs/gamedata/productdata.txt</a>",</p><p> "furnidata.load.url" : "<a href="https://worldmotel.nl/swfs/gamedata/furnidata.xml" target="_blank">https://worldmotel.nl/swfs/gamedata/furnidata.xml</a>",</p><p> "use.sso.ticket" : "0",</p><p> "sso.ticket" : "{sso}",</p><p> "client.starting" : "Please wait! {hotelName} is starting up.", </p><p> "processlog.enabled" : "0",</p><p> "flash.client.url" : BaseUrl + "/",</p><p> "flash.client.origin" : "popup"</p><p> };</p><p> var params = {</p><p> "base" : BaseUrl + "/",</p><p> "allowScriptAccess" : "always",</p><p> "menu" : "false" </p><p> };</p><p> swfobject.embedSWF(BaseUrl + "/Habbo.swf", "client", "100%", "100%", "10.1.0", BaseUrl + "/expressInstall.swf", flashvars, params, null);</p><p> </p><p> </p><p> </script></p><p> </head></p><p> <body></p><p></p><p> <div class="modal fade forgot-password" id="clientModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"></p><p> <div class="modal-dialog" role="document"></p><p> <div class="modal-content"></p><p> <div class="modal-header"></p><p> <span style="width: 70px;"><?php echo date('Y-m-d'); ?></span></p><p> <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span class="hidden-xs-up">Close</span></button></p><p> </div></p><p> <div class="modal-title"></p><p> <h3>Updates</h3></p><p> </div></p><p> <div class="modal-body"></p><p> <p id="clientModalBody"></p></p><p> </div></p><p> </div></p><p> </div></p><p> </div></p><p></p><p> <div id="client"></div></p><p></p><p> </body></p><p></p><p> <!-- Bootstrap Minified JS --></p><p> <script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js" type="text/javascript"></script></p><p></p><p></html></p></blockquote><p></p>
[QUOTE="LeZack, post: 393181, member: 61455"] [USER=73082]@Etrion[/USER] <?php // User gets checked if logged on in class.html.php $uid = $_SESSION['user']['id']; $conn = $db->PDO(); // Check for recent boxes opened $stmt = $conn->pdo->prepare("SELECT `item_id` FROM `cms_box_opened` WHERE `user_id` = :uid AND `received` = 0"); $stmt->bindParam(':uid', $uid, $db->PARAM_INT); $stmt->execute(); if($stmt->rowCount() > 0) { foreach($stmt as $box) { $users->giveUserItem($uid, $box['item_id']); } $stmt = $conn->pdo->prepare("UPDATE `cms_box_opened` SET `received` = 1 WHERE `user_id` = :uid"); $stmt->bindParam(':uid', $uid, $db->PARAM_INT); $stmt->execute(); } // Check for recent purchases of packages $stmt = $conn->pdo->prepare("SELECT `id` FROM `cms_packages_bought` WHERE `user_id` = :uid AND `itemsGiven` = 0 LIMIT 1"); $stmt->bindParam(':uid', $uid, $db->PARAM_INT); $stmt->execute(); if($stmt->rowCount() > 0) { $pid = $stmt->fetchColumn(); $p = $admin->packageDecode($pid); // Start Badge SQL $item_id = $p['item_id']; $bid = $p['badge_id']; $pCredits = ($users->getUserInfo($uid, 'credits') + $p['credits']); $pDuckets = ($users->getUserInfo($uid, 'activity_points') + $p['duckets']); if(!$users->hasBadge($uid, $bid)) { // User doesn't have this badge $users->giveUserBadge($uid, $bid); } // End Badge SQL // Start Item SQL // Check if package includes more than 1 item $number = substr($p['item_name'], 0, 1); if(is_numeric($number)) { //$number equals amount of items to be given by first character in item_name.. for($i = 0; $i < $number; $i++) { $users->giveUserItem($uid, $item_id); } } else { // Give user 1 item $users->giveUserItem($uid, $item_id); } // End Item SQL // Give user amount of credits and duckets $users->updateUser($uid, 'credits', $pCredits); $users->updateUser($uid, 'activity_points', $pDuckets); $stmt = $conn->pdo->prepare("UPDATE `cms_packages_bought` SET `itemsGiven` = 1 WHERE `user_id` = :uid AND `id` = :pid LIMIT 1"); $stmt->bindParam(':uid', $uid, $db->PARAM_INT); $stmt->bindParam(':pid', $pid, $db->PARAM_INT); $stmt->execute(); } $conn = null; ?> <!DOCTYPE html> <html lang="da"> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8"> <title>{hotelName}: Hotel</title> {favicons} <link rel="stylesheet" href="static/css/client.css" type="text/css"> <link href="{hotelurl}/static/css/modal.min.css" rel="stylesheet" /> <link href="{hotelurl}/static/css/bootstrap.min.css" rel="stylesheet" /> <link href="{hotelurl}/static/css/habbo-theme.css" rel="stylesheet" /> <link href="{hotelurl}/static/css/newhabbo.css" rel="stylesheet" /> <link href="//fonts.googleapis.com/css?family=Ubuntu:400,300,700" rel="stylesheet" type="text/css" /> <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> <script type="text/javascript" src="{hotelurl}/static/js/ajax/swiffy-v2.3.js"></script> <script type="text/javascript"> var BaseUrl = "[URL]https://worldmotel.nl/swfs/gordon/PRODUCTION-201601012205-226667486[/URL]"; var flashvars = { "client.allow.cross.domain" : "1", "client.notify.cross.domain" : "0", "connection.info.host" : "EMPTY", "connection.info.port" : "30000", "site.url" : "[URL]https://worldmotel.nl[/URL]", "url.prefix" : "[URL]https://worldmotel.nl[/URL]", "client.reload.url" : "{hotelurl}/client", "client.fatal.error.url" : "{hotelurl}/me", "client.connection.failed.url" : "{hotelurl}/me", "external.variables.txt" : "[URL]https://worldmotel.nl/swfs/gamedata/external_variables.txt[/URL]", "external.texts.txt" : "[URL]https://worldmotel.nl/swfs/gamedata/external_flash_texts.txt[/URL]", "external.override.texts.txt" : "[URL]https://worldmotel.nl/swfs/gamedata/override/external_flash_override_texts.txt[/URL]", "external.override.variables.txt" : "[URL]https://worldmotel.nl/swfs/gamedata/override/external_override_variables.txt[/URL]", "external.figurepartlist.txt" : "[URL]https://worldmotel.nl/swfs/gamedata/figuredata.xml[/URL]", "productdata.load.url" : "[URL]https://worldmotel.nl/swfs/gamedata/productdata.txt[/URL]", "furnidata.load.url" : "[URL]https://worldmotel.nl/swfs/gamedata/furnidata.xml[/URL]", "use.sso.ticket" : "0", "sso.ticket" : "{sso}", "client.starting" : "Please wait! {hotelName} is starting up.", "processlog.enabled" : "0", "flash.client.url" : BaseUrl + "/", "flash.client.origin" : "popup" }; var params = { "base" : BaseUrl + "/", "allowScriptAccess" : "always", "menu" : "false" }; swfobject.embedSWF(BaseUrl + "/Habbo.swf", "client", "100%", "100%", "10.1.0", BaseUrl + "/expressInstall.swf", flashvars, params, null); </script> </head> <body> <div class="modal fade forgot-password" id="clientModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"> <div class="modal-dialog" role="document"> <div class="modal-content"> <div class="modal-header"> <span style="width: 70px;"><?php echo date('Y-m-d'); ?></span> <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span class="hidden-xs-up">Close</span></button> </div> <div class="modal-title"> <h3>Updates</h3> </div> <div class="modal-body"> <p id="clientModalBody"></p> </div> </div> </div> </div> <div id="client"></div> </body> <!-- Bootstrap Minified JS --> <script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js" type="text/javascript"></script> </html> [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Q&A
#SOLVED Client Stock At 76 Precent #PLUSEMU
Top