From 246261cdbea440df3620fe0304af8e3ae976c095 Mon Sep 17 00:00:00 2001 From: Shadez Date: Sun, 24 Oct 2010 10:30:03 +0900 Subject: [PATCH] [411] Final fix for achievements comparison --- character-achievements.php | 3 +-- includes/classes/class.characters.php | 14 ++++++-------- includes/revision_nr.php | 2 +- 3 files changed, 8 insertions(+), 11 deletions(-) diff --git a/character-achievements.php b/character-achievements.php index 5c464abda..9496b9b87 100644 --- a/character-achievements.php +++ b/character-achievements.php @@ -3,7 +3,7 @@ /** * @package World of Warcraft Armory * @version Release Candidate 1 - * @revision 397 + * @revision 411 * @copyright (c) 2009-2010 Shadez * @license http://opensource.org/licenses/gpl-license.php GNU Public License * @@ -70,7 +70,6 @@ $i++; } } - // $name = $comparisonData[0]['name']; } $realmId = $utils->GetRealmIdByName($_GET['r']); diff --git a/includes/classes/class.characters.php b/includes/classes/class.characters.php index cdd4bb294..a5035760a 100644 --- a/includes/classes/class.characters.php +++ b/includes/classes/class.characters.php @@ -3,7 +3,7 @@ /** * @package World of Warcraft Armory * @version Release Candidate 1 - * @revision 410 + * @revision 411 * @copyright (c) 2009-2010 Shadez * @license http://opensource.org/licenses/gpl-license.php GNU Public License * @@ -743,7 +743,7 @@ public function GetHeader() { 'gender' => null, 'genderId' => $this->gender, 'guildName' => ($this->guild_id > 0) ? $this->guild_name : null, - 'guildUrl' => ($this->guild_id > 0) ? sprintf('r=%s&gn=%s', urlencode($this->armory->currentRealmInfo['name']), urlencode($this->guild_name)) : null, + 'guildUrl' => ($this->guild_id > 0) ? sprintf('r=%s&gn=%s', urlencode($this->GetRealmName()), urlencode($this->guild_name)) : null, 'lastModified' => null, 'level' => $this->level, 'name' => $this->name, @@ -751,12 +751,12 @@ public function GetHeader() { 'prefix' => $this->character_title['prefix'], 'race' => $this->raceText, 'raceId' => $this->race, - 'realm' => $this->armory->currentRealmInfo['name'], + 'realm' => $this->GetRealmName(), 'suffix' => $this->character_title['suffix'], 'titleId' => $this->character_title['titleId'], ); if(Utils::IsWriteRaw()) { - $header['guildUrl'] = ($this->guild_id > 0) ? sprintf('r=%s&gn=%s', urlencode($this->armory->currentRealmInfo['name']), urlencode($this->guild_name)) : null; + $header['guildUrl'] = ($this->guild_id > 0) ? sprintf('r=%s&gn=%s', urlencode($this->GetRealmName()), urlencode($this->guild_name)) : null; } return $header; } @@ -1094,8 +1094,6 @@ public function CalculateCharacterTalents() { } } $talent_data = array('points' => $talent_points); - //print_r($talent_data); - //die; return $talent_data; } @@ -2610,12 +2608,12 @@ public function GetCharacterFeed($full = false) { if($achievement_info['categoryId'] == 81) { // Feats of strenght $feed_data[$i]['title'] = sprintf('%s [%s].', $_strings[14], $achievement_info['title']); - $feed_data[$i]['desc'] = sprintf('%s [%s]', $_strings[14], urlencode($this->armory->currentRealmInfo['name']), urlencode($this->name), $tooltip, $achievement_info['title']); + $feed_data[$i]['desc'] = sprintf('%s [%s]', $_strings[14], urlencode($this->GetRealmName()), urlencode($this->name), $tooltip, $achievement_info['title']); } else { $points_string = sprintf($_strings[18], $achievement_info['points']); $feed_data[$i]['title'] = sprintf('%s [%s].', $_strings[13], $achievement_info['title']); - $feed_data[$i]['desc'] = sprintf('%s [%s] %s.', $_strings[13], urlencode($this->armory->currentRealmInfo['name']), urlencode($this->name), $tooltip, $achievement_info['title'], $points_string); + $feed_data[$i]['desc'] = sprintf('%s [%s] %s.', $_strings[13], urlencode($this->GetRealmName()), urlencode($this->name), $tooltip, $achievement_info['title'], $points_string); } $feed_data[$i]['tooltip'] = $tooltip; break; diff --git a/includes/revision_nr.php b/includes/revision_nr.php index 4438d9fdb..1ce4acaf5 100644 --- a/includes/revision_nr.php +++ b/includes/revision_nr.php @@ -1,5 +1,5 @@ \ No newline at end of file