Skip to content
Mottie edited this page Sep 14, 2013 · 2 revisions

Wiki Pages: Home | Setup | Options | Theme | Change

Sections: Appearance | Guild Info | Language | Tooltips | Callbacks

  • Set the number of news items to show within the news window.
  • Values must be between 0 and 25.
  • The maximum number of items is limited by the feed.
  • Default value is 25.
  • Set the size of the icon image to retrieve.
  • When set to true the icon image is 18x18 pixels in size. If false the image is 56x56 pixels in size.
  • These image sizes are provided by Blizzard, so choose the image size you want, then adjust it using the css as desired.
  • The css class name that sets the size of the icons is named wow-icon-small and wow-icon-large.
  • Default value is true.
  • This must be set to the battle.net domain.
  • China's battle.net does not have a domain, but you can set this value to "cn" and the plugin will use the correct API domain.
  • Values include: "us", "eu", "kr", "tw" or "sea"; use "cn" for China.
  • Default value is "us".
  • This sets the language to use.
  • Values include : "en" (English), "es" (Spanish), "pt" (Portuguese), "fr" (French), "ru" (Russian), "de" (German), "it" (Italian), "ko" (Korean) or "zh" (Chinese).
  • Note that this locale value is also used when setting the locale for the tooltip urls, so if this locale isn't available by the tooltip site (wowhead by default), then you can change the tooltip URL string directly.
  • Default value is "en" (English).
  • Set the server name to use here.
  • Only one server is usable per news feed.
  • Include any spaces and apostrophes in the server name and make sure it is within double quotes.
  • Default is "Lightning's Blade" to show that double quotes should be surrounding the name with an apostrophe.
  • Set your guild's name here.
  • Include spaces, apostrophes and special characters in the name, and make sure it is within double quotes.
  • Default is "Our Guild's Name" to show that double quotes should be surrounding the name with an apostrophe.

This option can be separated into five parts: guild info template, news item listing, item action, guild reference and time.

Guild info template

  • guildinfo

    • This is the template for the guild information that shows up below the guild name at the top of the window.
    • The default value is "(Level {level} {faction} Guild, {server})".
    • {level} is replaced by the guild level.
    • {faction} is replaced by the guild faction (Alliance or Horde), as defined by the next option.
    • {server} is replaced by the guild's server name.
    • Change the order, remove any variable, or change the language in the template as desired.
  • faction

    • This option contains the name of the factions: Alliance and Horde.

    • Change the language as desired.

    • If Blizzard ever decides to add a third faction and hopefully supports it in the API, then just add it to the string, e.g.

      "faction" : [ "Alliance", "Horde", "Gnomes" ],

News Item Listing

  • The news item can either report the action of how an item is received (purchased, crafted or obtained) or a personal or guild achievement.

  • The Item news listing template looks like this, with examples:

    "item" : "{icon} {player} {action} {item}. {time}"
    // results in:
    // [icon] Fred purchased [Foo]. 1 hour ago.
    // [icon] Barney crafted [Bar]. Yesterday.
    // [icon] Dino obtained [Bone]. 15 minutes ago.
    • {icon} is replaced by the item's icon.
    • {player} is replaced by the name of the character which received the item. It also links to the characted in the Blizzard armory.
    • {action} is replaced by the method at which the characted received the item (purchased, crafted or obtained).
    • {item} is replaced by a wowhead tooltip with the name of the item colorized to match the item quality.
    • {time} is replaced by an easily readable time as shown in the examples above.
    • Change the template order as desired.
    • The template is treated as if it is HTML, so add any HTML inside as desired, e.g. "{icon} <strong>{player}</strong> {action} {item}. {time}".
  • The Achievement news lists template looks like this, with examples:

    "{icon} {player} earned the achievement {ach} for {points} points. {time}"
    // results in:
    // [icon] Dino earned the achievement [Bark] for 10 points. 45 minutes ago.
    // [icon] The guild earned the acheivement [Super Cool] for 10 points. Just now.
    • {icon} is replaced by the achievement icon.
    • {player} is replaced by the name of the character (with a link to the armory) which received the item, or a reference to the guild (see the guild text option below).
    • {ach} is replaced by the name of the achievement as well as a wowhead tooltip showing details of the achievement.
    • {points} is replaced by the number of points the achievement was worth.
    • {time} is replaced by an easily readable time as shown in the examples above.
    • Change the template order as desired.
    • The template is treated as if it is HTML, so add any HTML inside as desired, e.g. "{icon} <strong>{player}</strong> earned {ach} {time}.".

item action

  • The next three text options replace the {action} string as appropriate.

  • These options allow you to change the language or wording (on the right side of the "key" : "value" pairs below).

    "obtained"  : "obtained",
    "crafted"   : "crafted",
    "purchased" : "purchased",

    here's an example:

    "obtained"  : "looted",
    "crafted"   : "made",
    "purchased" : "bought",

guild reference

  • This text option replaces the {player} when an achievement is earned by the guild.

  • Change the language or wording as desired:

    // default: "guild" : "The guild"
    "guild" : "Our awesome guild"
    // results in:
    // [icon] Our awesome guild earned the acheivement [Super Cool] for 10 points. Just now.

time

  • This text option replaces the {time} with a more readable format.

  • Change the language or wording as desired.

  • future and past options were added in v1.1 beta. "ago" was removed from the other options

  • Hopefully this list is self explanatory:

    "future" : "in",
    "past"   : "ago",
    "recent" : "Recently", // only shown if time is somehow negative - issues with daylight savings?
    "now"    : "Just now",
    "min"    : "1 minute",
    "mins"   : "minutes",  // greater than 1 minute ago
    "hour"   : "1 hour",
    "hours"  : "hours",    // greater than 1 hour ago
    "yday"   : "Yesterday",
    "days"   : "days",     // greater than 1 day ago
    "weeks"  : "weeks"     // 2 or more weeks ago (kicks in around 11 days; it rounds up)

showFutureTime

  • This option was added in verison 1.1 beta

  • Battle.net armory shows future times (e.g. "in 10 minutes"); keeping this option as true makes this widget mimics that behavior.

  • To change all future times to show "Recently" (set by the time option recent value), set this option to false.

    showFutureTime : true,
  • The tooltips are split into an item and acheivement tooltip.

    itemTooltip : "http://{locale}.wowhead.com/item={id}",
    achTooltip  : "http://{locale}.wowhead.com/achievement={id}"
    • The {locale} variable is replaced by the value from the locale option.
    • Because wowhead doesn't support all of the same locales as Blizzard, you can replace the {locale} variable in this string.
    • Wowhead regions include: www (U.S.), ptr (public test realm), de (German), es (Spanish), fr (French) and ru (Russian).
    • Note that the "en" region automatically becomes "www" in the URL.
    • I originally added this in case you wanted to use wowdb.com tooltips, but apparently their tooltips don't support dynamically added HTML, meaning the HTML has to exist on the page when the script is loaded; any new HTML added to the page after it initializes is ignored.
  • This callback function can be used to perform any necessary operations after the progression box has completed setting up.

  • In this example, the callback is setting up the tooltip plugin.

    initialized: function(el){
      // do something awesome
    }
  • The el parameter of the function contains the element that the plugin was initialized on.

  • The default value is undefined.

Clone this wiki locally