• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Solved Znote tfs1.2 shop error

Joriku

Working in the mines, need something?
Joined
Jul 16, 2016
Messages
1,085
Solutions
15
Reaction score
379
Location
Sweden
YouTube
Joriku
So, i've been trying to change the shop abit and now i get this error while selling mounts
f845312074f16fb64e09c95872b2d8ac.png
 
Solution
let me know if it works. I have not tested this but it should be a good.

by the way, use the CODE editor at the forum because it looks not neatly

PHP:
<?php
require_once 'engine/init.php';
include 'layout/overall/header.php';
protect_page();
admin_only($user_data);

$orders = mysql_select_multi('SELECT * FROM `znote_shop_orders` ORDER BY `id` DESC;');
$order_types = array(1 => 'Item', 2 => 'Premium Days', 3 => 'Gender Change', 4 => 'Name Change', 5 => 'Outfit', 6 =>'Mount', 7 =>'Custom');
$items = getItemList();
?>
<h1>Shop Logs</h1>

<h2>Pending Orders</h2>
<p>These are pending orders, like items bought, but not received or used yet.</p>
<table>
    <thead>
        <th>Id</th>
        <th>Account</th>...
Where exacly do i put this?

--------- (69 Rows)
<?php
require_once 'engine/init.php';
include 'layout/overall/header.php';
protect_page();
admin_only($user_data);

$orders = mysql_select_multi('SELECT * FROM `znote_shop_orders` ORDER BY `id` DESC;');
$order_types = array(1 => 'Item', 2 => 'Premium Days', 3 => 'Gender Change', 4 => 'Name Change', 5 => 'Custom');
$items = getItemList();
?>
<h1>Shop Logs</h1>

<h2>Pending Orders</h2>
<p>These are pending orders, like items bought, but not received or used yet.</p>
<table>
<thead>
<th>Id</th>
<th>Account</th>
<th>Type</th>
<th>Item</th>
<th>Count</th>
<th>Date</th>
</thead>
<tbody>
<?php foreach(($orders ? $orders : array()) as $order) { ?>
<tr>
<td><?php echo $order['id']; ?></td>
<td><?php echo user_account_id_from_name($order['account_id']); ?></td>
<td><?php echo $order_types[$order['type']] ?></td>
<td><?php echo '(' . $order['itemid'] . ') ', (isset($items[$order['itemid']])) ? $items[$order['itemid']] : ''; ?></td>
<td><?php echo $order['count'] ?></td>
<td><?php echo date('Y/m/d H:i', $order['time']) ?></td>
</tr>
<?php } ?>
</tbody>
</table>

<?php
$orders = mysql_select_multi("SELECT `id`, `account_id`, `type`, `itemid`, `count`, `points`, `time` FROM `znote_shop_logs` ORDER BY `id` DESC;");
?>
<h2>Order History</h2>
<p>This list contains all transactions bought in the shop.</p>
<table>
<thead>
<th>Id</th>
<th>Account</th>
<th>Type</th>
<th>Item</th>
<th>Count</th>
<th>points</th>
<th>Date</th>
</thead>
<tbody>
<?php foreach(($orders ? $orders : array()) as $order) { ?>
<tr>
<td><?php echo $order['id']; ?></td>
<td><?php echo $order['account_id']; ?></td>
<td><?php echo $order_types[$order['type']] ?></td>
<td><?php echo '(' . $order['itemid'] . ') ', (isset($items[$order['itemid']])) ? $items[$order['itemid']] : ''; ?></td>
<td><?php echo $order['count'] ?></td>
<td><?php echo $order['points'] ?></td>
<td><?php echo getClock($order['time'], true, false); ?></td>
</tr>
<?php } ?>
</tbody>
</table>
<?php
include 'layout/overall/footer.php';
?>
 
let me know if it works. I have not tested this but it should be a good.

by the way, use the CODE editor at the forum because it looks not neatly

PHP:
<?php
require_once 'engine/init.php';
include 'layout/overall/header.php';
protect_page();
admin_only($user_data);

$orders = mysql_select_multi('SELECT * FROM `znote_shop_orders` ORDER BY `id` DESC;');
$order_types = array(1 => 'Item', 2 => 'Premium Days', 3 => 'Gender Change', 4 => 'Name Change', 5 => 'Outfit', 6 =>'Mount', 7 =>'Custom');
$items = getItemList();
?>
<h1>Shop Logs</h1>

<h2>Pending Orders</h2>
<p>These are pending orders, like items bought, but not received or used yet.</p>
<table>
    <thead>
        <th>Id</th>
        <th>Account</th>
        <th>Type</th>
        <th>Item</th>
        <th>Count</th>
        <th>Date</th>
    </thead>
    <tbody>
        <?php foreach(($orders ? $orders : array()) as $order) { ?>
        <tr>
            <td><?php echo $order['id']; ?></td>
            <td><?php echo user_account_id_from_name($order['account_id']); ?></td>
            <td><?php echo $order_types[$order['type']] ?></td>
            <td><?php echo '(' . $order['itemid'] . ') ', (isset($items[$order['itemid']])) ? $items[$order['itemid']] : ''; ?></td>
            <td><?php echo $order['count'] ?></td>
            <td><?php echo date('Y/m/d H:i', $order['time']) ?></td>
        </tr>
        <?php } ?>
    </tbody>
</table>

<?php
$orders = mysql_select_multi("SELECT `id`, `account_id`, `type`, `itemid`, `count`, `points`, `time` FROM `znote_shop_logs` ORDER BY `id` DESC;");
?>
<h2>Order History</h2>
<p>This list contains all transactions bought in the shop.</p>
<table>
    <thead>
        <th>Id</th>
        <th>Account</th>
        <th>Type</th>
        <th>Item</th>
        <th>Count</th>
        <th>points</th>
        <th>Date</th>
    </thead>
    <tbody>
        <?php foreach(($orders ? $orders : array()) as $order) { ?>
        <tr>
            <td><?php echo $order['id']; ?></td>
            <td><?php echo $order['account_id']; ?></td>
            <td><?php echo $order_types[$order['type']] ?></td>
            <td><?php echo '(' . $order['itemid'] . ') ', (isset($items[$order['itemid']])) ? $items[$order['itemid']] : ''; ?></td>
            <td><?php echo $order['count'] ?></td>
            <td><?php echo $order['points'] ?></td>
            <td><?php echo getClock($order['time'], true, false); ?></td>
        </tr>
        <?php } ?>
    </tbody>
</table>
<?php
include 'layout/overall/footer.php';
?>
 
Solution
let me know if it works. I have not tested this but it should be a good.

by the way, use the CODE editor at the forum because it looks not neatly

PHP:
<?php
require_once 'engine/init.php';
include 'layout/overall/header.php';
protect_page();
admin_only($user_data);

$orders = mysql_select_multi('SELECT * FROM `znote_shop_orders` ORDER BY `id` DESC;');
$order_types = array(1 => 'Item', 2 => 'Premium Days', 3 => 'Gender Change', 4 => 'Name Change', 5 => 'Outfit', 6 =>'Mount', 7 =>'Custom');
$items = getItemList();
?>
<h1>Shop Logs</h1>

<h2>Pending Orders</h2>
<p>These are pending orders, like items bought, but not received or used yet.</p>
<table>
    <thead>
        <th>Id</th>
        <th>Account</th>
        <th>Type</th>
        <th>Item</th>
        <th>Count</th>
        <th>Date</th>
    </thead>
    <tbody>
        <?php foreach(($orders ? $orders : array()) as $order) { ?>
        <tr>
            <td><?php echo $order['id']; ?></td>
            <td><?php echo user_account_id_from_name($order['account_id']); ?></td>
            <td><?php echo $order_types[$order['type']] ?></td>
            <td><?php echo '(' . $order['itemid'] . ') ', (isset($items[$order['itemid']])) ? $items[$order['itemid']] : ''; ?></td>
            <td><?php echo $order['count'] ?></td>
            <td><?php echo date('Y/m/d H:i', $order['time']) ?></td>
        </tr>
        <?php } ?>
    </tbody>
</table>

<?php
$orders = mysql_select_multi("SELECT `id`, `account_id`, `type`, `itemid`, `count`, `points`, `time` FROM `znote_shop_logs` ORDER BY `id` DESC;");
?>
<h2>Order History</h2>
<p>This list contains all transactions bought in the shop.</p>
<table>
    <thead>
        <th>Id</th>
        <th>Account</th>
        <th>Type</th>
        <th>Item</th>
        <th>Count</th>
        <th>points</th>
        <th>Date</th>
    </thead>
    <tbody>
        <?php foreach(($orders ? $orders : array()) as $order) { ?>
        <tr>
            <td><?php echo $order['id']; ?></td>
            <td><?php echo $order['account_id']; ?></td>
            <td><?php echo $order_types[$order['type']] ?></td>
            <td><?php echo '(' . $order['itemid'] . ') ', (isset($items[$order['itemid']])) ? $items[$order['itemid']] : ''; ?></td>
            <td><?php echo $order['count'] ?></td>
            <td><?php echo $order['points'] ?></td>
            <td><?php echo getClock($order['time'], true, false); ?></td>
        </tr>
        <?php } ?>
    </tbody>
</table>
<?php
include 'layout/overall/footer.php';
?>
Thx it works, do you know how i fix this? (Items, Mounts, Eq etc.) and premium scroll (Tibia Coins) Doesn't add points to the shop know how to fix this?
4813be1b3b19e0e2f334e078d10d40bf.png
 
I would suggest using the current store on the site. TFS 1.2 does not support the tibia coins. Let's hope that it will be introduced in the TFS 1.3
 
I would suggest using the current store on the site. TFS 1.2 does not support the tibia coins. Let's hope that it will be introduced in the TFS 1.3
okay, but do you know how i fix the tabs "All, ITEMS, PREMIUM,OUTFITS, MOUNTS.."
that all mounts are in mount tab and it need to be clicked on mount tab to show the mounts
 
Back
Top