Ejemplo n.º 1
0
;
</script>

<script type="text/javascript">//<![CDATA[
$.extend(window, {g_staticUrl: '<?php 
echo WoW::GetStaticUrl();
?>
', g_serverTime: new Date('<?php 
echo date('Y/m/d H:i:s');
?>
')});
//]]></script>

<?php 
echo WoW_Template::GetJSForPage();
switch (WoW_Template::GetPageIndex()) {
    case 'item':
    case 'items':
        echo sprintf('<script type="text/javascript" src="%sdata=weight-presets.zones"></script>', WoW::GetUrl());
        break;
    case 'talent':
        echo sprintf('<script type="text/javascript" src="%sdata=glyphs"></script>', WoW::GetUrl(), WoW_Locale::GetLocaleID());
        break;
    case 'npc':
        echo sprintf('<script type="text/javascript" src="%sdata=zones"></script>', WoW::GetUrl(), WoW_Locale::GetLocaleID());
        break;
    case 'search':
        echo sprintf('<script type="text/javascript" src="%sdata=realms.weight-presets"></script>', WoW::GetUrl(), WoW_Locale::GetLocaleID());
        break;
}
?>
Ejemplo n.º 2
0
/search"><input name="q" value="<?php 
echo WoW_Template::GetPageData('search_terms');
?>
" /></form></div>
<div class="topbar-buttons"></div>
</div>
<div class="main" id="main">
<div class="main-precontents" id="main-precontents"></div>
<div class="main-contents" id="main-contents">
<?php 
if (WoW_Template::GetPageAnnouncement() >= 0) {
    echo '<div id="announcement-' . WoW_Template::GetPageAnnouncement() . '"></div>';
}
?>

<?php 
if (WoW::IsRegisteredPage() && !WoW_Template::IsErrorPage()) {
    WoW_Template::LoadTemplate('block_set_page_template');
    // LOAD APPROPRIATE TEMPLATE FOR EACH REGISTERED PAGE HERE!
    WoW_Template::LoadTemplate('content_' . WoW_Template::GetPageIndex());
} else {
    WoW_Template::LoadTemplate('block_set_page_template_unknown');
    WoW_Template::LoadTemplate('content_error');
}
?>

<div class="clear"></div>

</div>
</div>
<li class="last"><a href="<?php 
echo WoW::GetWoWPath();
?>
/wow/game/guide/getting-started" rel="np"><?php 
echo WoW_Locale::GetString('template_menu_game_guide_playing_together');
?>
</a></li>
</ol>-->
</div>
<div class="content-bot">
		<div class="guide-top-nav">
<?php 
$game_guide_menu = array('game_guide_what_is_wow', 'game_guide_getting_started', 'game_guide_how_to_play', 'game_guide_playing_together', 'game_guide_late_game');
foreach ($game_guide_menu as $active_menu) {
    $menu_id = str_replace(array('game_guide_', '_'), array('', '-'), $active_menu);
    if (WoW_Template::GetPageIndex() == $active_menu) {
        echo '				<a class="btn-' . $menu_id . ' selected">
					<span>' . WoW_Locale::GetString('template_menu_game_chapter_' . $menu_id) . '</span>
				</a>';
    } else {
        echo '				<a href="' . WoW::GetWoWPath() . '/wow/game/guide/' . ($menu_id == 'what-is-wow' ? '' : $menu_id) . '" class="btn-' . $menu_id . '">
					<span>' . WoW_Locale::GetString('template_menu_game_chapter_' . $menu_id) . '</span>
				</a>';
    }
}
?>
	<span class="clear"><!-- --></span>
		</div>
		<div class="guide-intro-part">
			<div class="guide-section-title">
				<a href="<?php 
 public static function GetPageTitle()
 {
     switch (WoW_Template::GetPageIndex()) {
         case 'character_profile_simple':
         case 'character_profile_advanced':
             return sprintf('%s @ %s - %s - ', WoW_Characters::GetName(), WoW_Characters::GetRealmName(), WoW_Locale::GetString('template_menu_game'));
         case 'character_talents':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_profile_talents'), WoW_Locale::GetString('template_menu_game'));
         case 'character_achievements':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_profile_achievements'), WoW_Locale::GetString('template_menu_game'));
         case 'character_reputation':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_profile_reputation'), WoW_Locale::GetString('template_menu_game'));
         case 'character_statistics':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_profile_statistics'), WoW_Locale::GetString('template_menu_game'));
         case 'character_pvp':
             return sprintf('PvP - %s - ', WoW_Locale::GetString('template_menu_game'));
         case 'character_feed':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_character_feed'), WoW_Locale::GetString('template_menu_game'));
         case 'item':
             return sprintf('%s - ', WoW_Template::GetPageData('itemName'));
         case 'item_list':
             return sprintf('%s - ', WoW_Template::GetPageData('last-crumb'));
         case 'guild_page':
             return sprintf('%s @ %s - ', WoW_Guild::GetGuildName(), WoW_Guild::GetGuildRealmName());
         case 'guild_perks':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_guild_menu_perks'), WoW_Locale::GetString('template_menu_game'));
         case 'guild_roster':
         case 'guild_professions':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_guild_menu_roster'), WoW_Locale::GetString('template_menu_game'));
         case 'search':
             return WoW_Search::GetSearchQuery() != null ? sprintf('%s - %s - ', WoW_Search::GetSearchQuery(), WoW_Locale::GetString('template_search')) : sprintf('%s - ', WoW_Locale::GetString('template_search'));
         case 'realm_status':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_realm_status'), WoW_Locale::GetString('template_menu_game'));
         case 'blog':
             return sprintf('%s - ', WoW_Template::GetPageData('blog_title'));
         case 'game':
             return sprintf('%s - ', WoW_Locale::GetString('template_menu_game'));
         case 'game_guide_what_is_wow':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_menu_game_guide_what_is_wow'), WoW_Locale::GetString('template_menu_game'));
         case 'game_guide_getting_started':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_menu_game_guide_getting_started'), WoW_Locale::GetString('template_menu_game'));
         case 'game_guide_how_to_play':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_menu_game_guide_how_to_play'), WoW_Locale::GetString('template_menu_game'));
         case 'game_guide_playing_together':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_menu_game_guide_playing_together'), WoW_Locale::GetString('template_menu_game'));
         case 'game_guide_late_game':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_menu_game_guide_late_game'), WoW_Locale::GetString('template_menu_game'));
         case 'game_race_index':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_game_race_index'), WoW_Locale::GetString('template_menu_game'));
         case 'game_race':
             return sprintf('%s - %s - ', WoW_Locale::GetString('character_race_' . WoW_Template::GetPageData('raceId')), WoW_Locale::GetString('template_menu_game'));
         case 'game_class_index':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_game_class_index'), WoW_Locale::GetString('template_menu_game'));
         case 'game_class':
             return sprintf('%s - %s - ', WoW_Locale::GetString('character_class_' . WoW_Template::GetPageData('classId')), WoW_Locale::GetString('template_menu_game'));
         case 'password_reset':
             return sprintf('%s - Battle.Net', WoW_Locale::GetString('login_help_title'));
         case 'password_reset_select':
         case 'password_reset_secred_answer':
         case 'password_reset_success':
         case 'password_reset_confirm':
         case 'password_reset_changed':
             return sprintf('%s - Battle.Net', WoW_Locale::GetString('template_account_password_reset_title'));
         case 'dashboard':
             return sprintf('%s - Battle.Net', WoW_Locale::GetString('expansion_' . WoW_Account::GetExpansion()));
         case 'landing':
             switch (WoW_Template::GetPageData('landing')) {
                 case 'what_is':
                     return sprintf('%s - Battle.Net', WoW_Locale::GetString('template_bn_what_is_it_title'));
             }
             break;
         case 'creation_tos':
         case 'creation_success':
         case 'account_conversion':
         case 'management':
             return WoW_Locale::GetString('template_management_main_title');
             //[PH]
         //[PH]
         case 'auction_lots':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_auction_menu_lots'), WoW_Locale::GetString('template_menu_game'));
         case 'forum_index':
             return sprintf('%s - ', WoW_Locale::GetString('template_menu_forums'));
         case 'forum_category':
             return sprintf('%s - %s - ', WoW_Template::GetPageData('forum_category_title'), WoW_Locale::GetString('template_menu_forums'));
         case 'forum_thread':
             return sprintf('%s - %s - ', WoW_Template::GetPageData('forum_thread_title'), WoW_Locale::GetString('template_menu_forums'));
         case 'forum_blizztracker':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_blizztracker_title'), WoW_Locale::GetString('template_menu_forums'));
         case 'zones':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_game_dungeons_and_raids'), WoW_Locale::GetString('template_menu_game'));
         case 'zone':
             return sprintf('%s - %s - ', WoW_Template::GetPageData('zone_name'), WoW_Locale::GetString('template_menu_game'));
         case 'pvp_arena':
             return sprintf('PvP - %s - ', WoW_Locale::GetString('template_menu_game'));
         case 'character_companions_mounts':
             return sprintf('%s - %s - ', WoW_Locale::GetString('template_profile_' . WoW_Template::GetPageData('category') . 's'), WoW_Locale::GetString('template_menu_game'));
         case 'shop':
             return sprintf('%s - ', WoW_Locale::GetString('template_shop_title'));
         default:
             return '';
     }
 }
<div id="summary-stats-simple" class="summary-stats-simple"<?php 
echo WoW_Template::GetPageIndex() == 'character_profile_advanced' ? ' style="display:none;"' : null;
?>
>
			<div class="summary-stats-simple-base">

	<div class="summary-stats-column">
		<h4><?php 
echo WoW_Locale::GetString('template_profile_stats');
?>
</h4>
		<ul>
        <?php 
$strength = WoW_Characters::GetCharacterStrength();
$agility = WoW_Characters::GetCharacterAgility();
$stamina = WoW_Characters::GetCharacterStamina();
$intellect = WoW_Characters::GetCharacterIntellect();
$spirit = WoW_Characters::GetCharacterSpirit();
$melee_stats = WoW_Characters::GetMeleeStats();
$ranged_stats = WoW_Characters::GetRangedStats();
$spell = WoW_Characters::GetSpellStats();
$defense = WoW_Characters::GetDefenseStats();
$resistances = WoW_Characters::GetResistanceStats();
?>
	<li data-id="strength" class="">
		<span class="name"><?php 
echo WoW_Locale::GetString('stat_strength');
?>
</span>
		<span class="value"><?php 
echo $strength['effective'];
Ejemplo n.º 6
0
// Data check
if (WoW_Template::GetPageIndex() == 'data') {
    WoW_Template::LoadTemplate('block_data');
}
WoW_Template::LoadTemplate('block_header');
?>
<body class="<?php 
echo WoW::GetPageID();
?>
">

<div style="position: absolute; width: 1px; height: 1px; background: url('images/ui/wsa-notification.png') no-repeat"></div>

<!--
<div class="beta-ptr-links">
<div><a href="http://old.wowhead.com/" rel="np" title="View the old version of this page">&#171; Archive</a></div>
<div><a href="http://ptr.wowhead.com/" rel="np" title="View the PTR version of this page">&#171; PTR</a></div>
</div>
-->

<?php 
if (WoW_Template::GetPageIndex() == 'home') {
    WoW_Template::LoadTemplate('content_home');
} else {
    WoW_Template::LoadTemplate('block_layout');
}
WoW_Template::LoadTemplate('block_footer');
?>

</body>
</html>
Ejemplo n.º 7
0
 public static function IsRegisteredPage()
 {
     switch (WoW_Template::GetPageIndex()) {
         case 'achievements':
         case 'achievement':
         case 'classes':
         case 'class':
         case 'currencies':
         case 'currency':
         case 'factions':
         case 'faction':
         case 'pets':
         case 'pet':
         case 'itemsets':
         case 'itemset':
         case 'items':
         case 'item':
         case 'npcs':
         case 'npc':
         case 'objects':
         case 'object':
         case 'skills':
         case 'skill':
         case 'quests':
         case 'quest':
         case 'races':
         case 'race':
         case 'spells':
         case 'spell':
         case 'titles':
         case 'title':
         case 'events':
         case 'event':
         case 'zones':
         case 'zone':
         case 'talent':
         case 'petcalc':
         case 'filters':
         case 'compare':
         case 'profiler':
         case 'bluetracker':
         case 'maps':
         case 'guide':
         case 'patchnotes':
         case 'latest-achievements':
         case 'latest-additions':
         case 'latest-comments':
         case 'latest-screenshots':
         case 'latest-videos':
         case 'most-comments':
         case 'unrated-comments':
         case 'missing-screenshots':
         case 'random':
         case 'latest-replies':
         case 'latest-topics':
         case 'unanswered-topics':
         case 'latest-blog-comments':
         case 'blog':
         case 'forums':
         case 'website-achievements':
         case 'contests':
         case 'xfire':
         case 'irc':
         case 'aboutus':
         case 'advertise':
         case 'faq':
         case 'help':
         case 'jobs':
         case 'premium':
         case 'searchplugins':
         case 'logos':
         case 'whats-new':
         case 'client':
         case 'newsfeed':
         case 'searchbox':
         case 'tooltips':
         case 'search':
             return true;
         default:
             return false;
     }
 }
<script type="text/javascript">//<![CDATA[
<?php 
if (WoW_Locale::GetLocaleID() > 0) {
    echo sprintf('Locale.set(%d);', WoW_Locale::GetLocaleID());
}
?>

PageTemplate.set({pageName: '<?php 
echo WoW_Template::GetPageIndex();
?>
', activeTab: <?php 
echo WoW_Template::GetPageData('activeTab');
echo WoW_Template::GetPageData('disable_breadcrumb') != true ? ', breadcrumb: [' . WoW_Template::GetPageData('breadcrumb') . ']' : null;
?>
});
PageTemplate.init();
g_captchaType = 1;g_dataKey = '60770694807121612389db4ad8f344000d5cab78';g_host = 'http://www01.wowhead.com';
//]]></script>