by poetter » Sun Sep 30, 2007 9:18 pm
This is because a lot of data, like inventory items and quests can't be filled from the armory. this patch will fix the notices:
- Code: Select all
--- D:/xampp/roster.com/htdocs/addons/keys/guild/index.php.org Wed Sep 05 17:05:36 2007
+++ D:/xampp/roster.com/htdocs/addons/keys/guild/index.php Sun Sep 30 15:12:15 2007
@@ -96,8 +96,10 @@
function buildSQL($item,$key,$type)
{
global $selectp, $wherep, $pcount, $selectq, $whereq, $qcount;
-
- list($iname, $thottnum) = explode('|', $item);
+
+ $alist = explode('|', $item);
+
+ $iname = isset($alist[0]) ? $alist[0] : '';
if ($type == 'quest')
{
@@ -206,7 +208,7 @@
// ==============================
foreach ($items as $key => $item)
{
- if ($krow[$key] == '-1')
+ if ( isset($krow[$key]) && $krow[$key] == '-1')
{
++$kcount;
}
@@ -323,7 +325,7 @@
{
rankMid((($striping_counter % 2) +1));
}
- if ($krow[$key] == '-2')
+ if (isset($krow[$key]) && $krow[$key] == '-2')
{
$iname = $roster->locale->wordings[$row['clientLocale']]['thievestools'];
$iquery = "SELECT * FROM `" . $roster->db->table('items') . "` WHERE `item_name` = '$iname' AND `member_id` = '" . $row['member_id'] . "';";
@@ -332,7 +334,7 @@
$item = new item($idata, 'simple');
print $item->out($key);
}
- else if ($krow[$key] == '-1')
+ else if (isset($krow[$key]) && $krow[$key] == '-1')
{
list($iname, $thottnum) = explode('|', $data[$key]);
if(isset($$key))
@@ -349,11 +351,11 @@
print $$key;
}
}
- else if ($krow[$key] == '0')
+ else if (isset($krow[$key]) && $krow[$key] == '0')
{
print ' ';
}
- else if ($krow[$key] == '')
+ else if (!isset($krow[$key]) || $krow[$key] == '')
{
print ' ';
}