AssetTypeId == 9){ die(header("Location: /".replaceSpecialChars($cataloginfo->Name)."-place?id=".$id)); }
$inventory = json_decode($userInfo->Inventory,true);
//new item update part
//quite the yike organization wise tbh
/*if (isset($_POST['upload']))
{
$uploadOK = false;
$type = $_POST['type'];
if ($_POST['forsale'] == "on" and (($_POST['price-robux'] !== null and isset($_POST['price-robux'])) or ($_POST['price-tickets'] !== null and isset($_POST['price-tickets'])))) {
$forsale = 1;
}else {
$forsale = 0;
}
if ($type !== 4) {
if ($_POST['price-robux'] !== null and isset($_POST['price-robux'])) {
$priceRobux = $_POST['price-robux'];
}
if ($_POST['price-tickets'] !== null and isset($_POST['price-tickets'])) {
$priceTickets = $_POST['price-tickets'];
}
}
$description = $_POST['description'];
$title = $_POST['title'];
//check here if user is admin
$dbtype = $type;
$title = preg_replace("/[^ \w]+/", "", $title);
$title = preg_replace('!\s+!', ' ', $title);
$description = preg_replace('!\s+!', ' ', $description);
if (strlen($title) > 36) {
header("Location: /My/Item.aspx?id=".$id."&error=2");
exit;
}
if (strlen($title) < 1) {
header("Location: /My/Item.aspx?id=".$id."&error=5");
exit;
}
if (strlen($description) > 800) {
header("Location: /My/Item.aspx?id=".$id."&error=1");
exit;
}
if (($priceRobux < 0 and $priceTickets < 0) and $dbtype !== 13) {
header("Location: /My/Item.aspx?id=".$id."&error=4");
exit;
}
if (($priceRobux > 99999 or $priceTickets > 99999) and $dbtype !== 13) {
header("Location: /My/Item.aspx?id=".$id."&error=3");
exit;
}
if ($dbtype == 13) {
$priceRobux = 0;
$priceTickets = 0;
}
}*/
/*if (isset($_POST['upload'])) {
die(print_r($_POST));
}*/
//end item update
//now we can show the user their updated asset :)
/*if ($_SERVER['HTTP_USER_AGENT'] == 'Mozilla/5.0 (compatible; Discordbot/2.0; +https://discordapp.com)')
{ //Discord-specific embed
die('
'.htmlspecialchars($cataloginfo->Name).', a '.assetTypeToString($cataloginfo->AssetTypeId).' by '.getNameFromUid($cataloginfo->CreatorId).' - ROBLONIUM
');
}*/
if (isset($_POST['upload'])) {
if ($cataloginfo->CreatorId !== $_SESSION["player"] or verify_user() !== true) {
//They're legit
if ($_SESSION["player"] == 1 and verify_user() == true) {
}else {
Redirect("http://" . $_SERVER['SERVER_NAME'] . "/RobloxDefaultErrorPage.aspx");
die();
}
}
//moved up to prevent headers from being prematurely sent
if (isset($_POST['forsale']) and $_POST['forsale'] == "on" and (!isset($priceRobux) and !isset($priceTickets))) {
$forsale = 1;
$priceRobux = $cataloginfo->PriceInRobux;
$priceTickets = $cataloginfo->PriceInTickets;
}
if ($priceRobux == null) {
$priceRobux = 0; //could be skipped to make it null in database (MULTI-SELL)
}
if ($priceTickets == null) {
$priceTickets = 0; //could be skipped to make it null in database (MULTI-SELL)
}
if ($user->Robux < 0) {
echo('
' . alert('You do not have enough ROBUX.', '#dada01') . '
');
}else{
/*$user->Robux = $user->Robux-5;
$userinfo = $database->updateRow("public_users", [ // update code in secondary database
"Robux" => $user->Robux
], ["Id" => $user->Id]);*/
$newasset = $database->updateRow("asset", [
"Name" => $title,
"Description" => $description,
"PriceInRobux" => $priceRobux,
"PriceInTickets" => $priceTickets,
"IsForSale" => $forsale,
"Updated" => date('Y-m-d G:i:s')
], ["AssetId" => $cataloginfo->AssetId]);
echo('
' . alert('Asset successfully updated!', 'green') . '
');
}
//fetch the asset data again as it's now been updated by the user
// TODO: Make this more efficient
$asset = $itemApi->GetAssetInfo($id);
if ($asset === FALSE) {
Redirect("http://" . $_SERVER['SERVER_NAME'] . "/RobloxDefaultErrorPage.aspx");
die();
}
}
$page_config["ScriptIncludes"] =
[
"DataPager.js",
"PlaceProductPromotion.js",
"GamePass.js",
"VotingPanel.js",
"jquery.dotdotdot-1.5.7-packed.js",
"PrivateGameInstances/PrivateGameInstances.js",
"PrivateGameInstances/GetOrUseAccessCodeModal.js",
"widgets/Favorites.js",
"NewGamePage.js",
"modules/Widgets/AvatarImage.js",
"LaunchApp.js",
"fileUploadUnsupported.js",
"jquery.simplemodal-1.3.5.js",
"GenericModal.js",
"ItemPurchase.js",
"modules/Widgets/ItemImage.js",
"CommentsPane.js",
"SuperSafePrivacyIndicator.js",
"GenericConfirmation.js"
];
$page_config["CSSIncludes"] =
[
"CSS/Widgets/Flyouts.css",
"CSS/Pages/VotingPanel.css",
"CSS/Pages/PrivateGameInstances/PrivateGameInstances.css",
//"CSS/PartialViews/Navigation.css",
"CSS/Pages/GamePage.css",
"CSS/Widgets/Favorites.css",
"CSS/Pages/Thumbnails/AssetMedia.css"
];
require $_SERVER["DOCUMENT_ROOT"] . "/puzzle/Top.php";?>
">
=htmlspecialchars($cataloginfo->Name)?>
ROBLONIUM =assetTypeToString($cataloginfo->AssetTypeId)?>
=htmlspecialchars($cataloginfo->Description)?>
=htmlspecialchars($cataloginfo->Description)?>
IsForSale || ($inventory && in_array($cataloginfo->AssetId,$inventory['Inventory'])))
{ $purchaseDisabled = "disabled-"; $purchasedTooltip = 'original-title="You already own this item."'; }
else
{ $purchaseDisabled = $purchasedTooltip = false; }
if($cataloginfo->PriceInRobux + $cataloginfo->PriceInTickets == 0) { ?>
PriceInRobux){ ?>
Price: =number_format($cataloginfo->PriceInRobux)?>
>
Buy with R$
Buy with R$
PriceInRobux && $cataloginfo->PriceInTickets) {?>
PriceInTickets) { ?>
Price: =number_format($cataloginfo->PriceInTickets)?>
>
Buy with Tx
Buy with Tx
0
PRIVATE SALES
Sorry, no one is privately selling this item at the moment.