SMFShop > Modifications
SMFShop Inventory Post Modification
Aimee:
Awww its not compatable with 2.0 RC3 yet is it! Please can you upgrade it as I love this mod!
pilladoll:
Installed and Working!!
well, most of my users speaks spanish, so i made a traduction. Hope you find it useful. Just copy on /Themes/default/languages/Modifications.YOUR_LAUNGUAGE.php:
--- Code: ---// Shop Inventory Post Mod by Pilla
$txt['shop_ip_display'] = 'Mostrar en el Post el Inventario?';
$txt['shop_ip_display_max'] = 'Cantidad máxima de objetos del inventario a mostrar*';
$txt['shop_ip_display_max_tip'] = '*Se recomienda no exceder los 20 objetos';
$txt['shop_ip_position'] = 'Localización de la Muestra de Inventario en el Post';
$txt['shop_ip_position_postbit'] = 'Cuadro de Perfil';
$txt['shop_ip_position_sig'] = 'Firma';
$txt['shop_admin_shop_IPM'] = 'Muestra de Inventario en el Post';
$txt['shop_admin_IPM'] = 'Configurar la Muestra de Inventario en el Post';
$txt['shop_ip_admin_title'] = 'Configurar Muestra de Inventario en el Post';
$txt['shop_ip_display_yes'] = 'Sí';
$txt['shop_ip_display_no'] ='No';
--- End code ---
DTeK:
Would someone please help me install index.php and load.php? I am having problems. :( I can't really work out how to use install.xml and those are the two files that didn't install through the package manager. I really need this mod.
1. Execute Modification ./Sources/Load.php Test failed
2. Execute Modification ./index.php Test failed
3. Execute Modification ./Sources/Subs.php Test successful
4. Execute Modification ./Themes/default/index.template.php Test successful
5. Execute Modification ./Themes/default/languages/Shop.english.php Test successful
6. Execute Modification ./Sources/shop/ShopAdmin.php Test successful
7. Execute Modification ./Themes/default/ShopAdmin.template.php Test successful
8. Execute Modification ./Themes/default/Display.template.php Test successful
9. Execute Code dbInstall.php
hcfwesker:
Are you sure you're using smf shop version 3?
Here are the edits
Sources/Load.php
Find
--- Code: --- // Begin SMFShop MOD Version New Version
'money' => $profile['money'],
// End SMFShop MOD
--- End code ---
Replace with
--- Code: --- // Begin SMFShop MOD Version New Version
'money' => $profile['money'],
// End SMFShop MOD
//BEGIN SMFShop IPM
'shopitems' => $profile['shopitems']['shopitems'],
//END SMFShop IPM
--- End code ---
Find
--- Code: --- // What a monstrous array..
--- End code ---
Add Before
--- Code: ---//BEGIN SMFShop IPM
//Set variable for LIMIT amount
$row = 0;
$max = $modSettings['ShopIpDisMax'];
//Begin database query
$request3 = db_query("
SELECT it.desc, it.image, it.category, inv.id
FROM {$db_prefix}shop_inventory AS inv, {$db_prefix}shop_items AS it
WHERE inv.ownerid = {$profile['ID_MEMBER']} AND inv.itemid = it.id
LIMIT $max", __FILE__, __LINE__);
//Start with an empty array
$profile['shopitems']['shopitems'] = array();
//Loop through all items
while ($row = mysql_fetch_assoc($request3))
{
// Add item to the array
$profile['shopitems']['shopitems'][] = array(
'image' => $row['image'],
'desc' => $row['desc'],
);
}
mysql_free_result($request3);
//END SMFShop IPM
--- End code ---
And, your index.php
Find
--- Code: --- // End SMFShop code
);
--- End code ---
Add Before
--- Code: --- //BEGIN SMFShop IPM
'shop_IPM' => array('shop/ShopAdmin.php', 'ShopIPM'),
//END SMFShop IPM
--- End code ---
I recommend using this package parser, when you're not sure of edits to make
http://resourcez.biz/PackageParser/
Hope that helps.
k12onos:
Is this mod still supported? does it work with the latest SMF version? this mod is really neat, I hope it's still supported I want to install it in SMF 2.0 but i'm afraid it will mess things up :(
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version