Skip to content

Instantly share code, notes, and snippets.

@jasonroelofs
Created January 30, 2009 14:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jasonroelofs/55085 to your computer and use it in GitHub Desktop.
Save jasonroelofs/55085 to your computer and use it in GitHub Desktop.
CmdUtils.CreateCommand({
name: "wowhead",
arguments: [{role: 'object', nountype: noun_arb_text, label: 'query'}],
icon: "http://www.wowhead.com/favicon.ico",
homepage: "http://www.wowhead.com",
author: { name: "Carlos Moll", email: "carlos@tallon.org"},
license: "MPL,GPL",
description: "Search Wowhead",
help: "Search for an item, quest, NPC, etc on Wowhead",
execute: function(args) {
var url = "http://www.wowhead.com/?search={QUERY}"
var query = args.object.text;
var urlString = url.replace("{QUERY}", query);
Utils.openUrlInBrowser(urlString);
},
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment