diff --git a/includes/ajaxHandler.class.php b/includes/ajaxHandler.class.php index 9790c37d..a55c6e8a 100644 --- a/includes/ajaxHandler.class.php +++ b/includes/ajaxHandler.class.php @@ -113,7 +113,7 @@ class AjaxHandler protected static function checkFulltext(string $val) : string { // trim non-printable chars - return preg_replace('/[\p{Cf} \p{Co} \p{Cs} \p{Cn}]/ui', '', $val); + return preg_replace('/[\p{Cf}\p{Co}\p{Cs}\p{Cn}]/ui', '', $val); } } ?> diff --git a/includes/markup.class.php b/includes/markup.class.php index 8a4f3fc8..cb69efc5 100644 --- a/includes/markup.class.php +++ b/includes/markup.class.php @@ -31,7 +31,8 @@ class Markup $match[1] = 'achievement'; else if ($match[1] == 'icondb') $match[1] = 'icon'; - else if ($match[1] == 'money') + + if ($match[1] == 'money') { if (stripos($match[0], 'items')) { diff --git a/pages/spell.php b/pages/spell.php index 4e803ff1..34ab28c5 100644 --- a/pages/spell.php +++ b/pages/spell.php @@ -1234,12 +1234,7 @@ class SpellPage extends GenericPage return false; $item = DB::Aowow()->selectRow(' - SELECT name_loc0, name_loc2, name_loc3, name_loc6, name_loc8, i.id, ic.name AS iconString, quality, - IF ( (spellId1 > 0 AND spellCharges1 < 0) OR - (spellId2 > 0 AND spellCharges2 < 0) OR - (spellId3 > 0 AND spellCharges3 < 0) OR - (spellId4 > 0 AND spellCharges4 < 0) OR - (spellId5 > 0 AND spellCharges5 < 0), 1, 0) AS consumed + SELECT name_loc0, name_loc2, name_loc3, name_loc6, name_loc8, i.id, ic.name AS iconString, quality FROM ?_items i LEFT JOIN ?_icons ic ON ic.id = i.iconId WHERE i.id = ?d', @@ -1253,9 +1248,6 @@ class SpellPage extends GenericPage $_level++; - if ($item['consumed']) - $_qty++; - $data = array( 'type' => TYPE_ITEM, 'typeId' => $item['id'], @@ -1286,6 +1278,7 @@ class SpellPage extends GenericPage SELECT reagent1, reagent2, reagent3, reagent4, reagent5, reagent6, reagent7, reagent8, reagentCount1, reagentCount2, reagentCount3, reagentCount4, reagentCount5, reagentCount6, reagentCount7, reagentCount8, name_loc0, name_loc2, name_loc3, name_loc6, name_loc8, + iconIdBak, s.id AS ARRAY_KEY, ic.name AS iconString FROM ?_spell s JOIN ?_icons ic ON s.iconId = ic.id @@ -1327,6 +1320,11 @@ class SpellPage extends GenericPage if ($row['reagent'.$i] <= 0 || $row['reagentCount'.$i] <= 0) continue; + // handle edge case elemental crafting material: Mote of X + Crystalized X + // on use items, that has require more reagents of itself + if ($row['reagentCount'.$i] == 9 && ($row['iconIdBak'] == 140 || $row['iconIdBak'] == 1921)) + $row['reagentCount'.$i]++; + if ($this->appendReagentItem($reagentResult, $row['reagent'.$i], $row['reagentCount'.$i], $data['qty'], $data['level'], $data['path'], $_aU)) { $hasUnusedReagents = true; diff --git a/static/css/global.css b/static/css/global.css index 4fce05cc..0c79ae17 100644 --- a/static/css/global.css +++ b/static/css/global.css @@ -477,7 +477,7 @@ } .iconlist td { - padding: 4px 0 6px 0 !important; + padding: 4px 0 6px 0; } .iconlist var { diff --git a/static/js/Markup.js b/static/js/Markup.js index 72b7cab9..c3c2f052 100644 --- a/static/js/Markup.js +++ b/static/js/Markup.js @@ -2798,7 +2798,7 @@ var Markup = { border: { req: false, valid: /^[0-9]+$/ }, cellspacing: { req: false, valid: /^[0-9]+$/ }, cellpadding: { req: false, valid: /^[0-9]+$/ }, - width: { req: false, valid: /^[0-9]+(px|em|\%)$/ } + width: { req: false, valid: /^([0-9]+(px|em|\%)|auto)$/ } }, toHtml: function(attr) { diff --git a/template/pages/home.tpl.php b/template/pages/home.tpl.php index 30beec2c..5517798e 100644 --- a/template/pages/home.tpl.php +++ b/template/pages/home.tpl.php @@ -85,7 +85,7 @@ endif; |Github|