User:Poke/GuildWarsWikiTools

From Guild Wars Wiki
< User:Poke(Redirected from User:Poke/GWWT)
Jump to navigationJump to search
Guild Wars Wiki Tools

Guild Wars Wiki Tools (GWWT) is a comprehensive set of tools made for the official Guild Wars Wiki and the official Guild Wars 2 Wiki. It was developed to ease and speed up the work with the wiki.

GWWT currently consists javascript tool Guild Wars Wiki Tools and some minor addons. However there are a lot future plans for more powerful programs.

Bugs and feature requests are handled on the talk page.

Licensing

As it is not possible to disallow others from copying the code of GWWT, due to the licensing terms on this wiki, please consider the following:
If the code of Guild Wars Wiki Tools is copied to any other website, wiki or wiki page by anyone other than me, I will drop the complete support for all users that copied the code or used the code. This applies to all current and future versions of Guild Wars Wiki Tools.

Guild Wars Wiki Tools v1.2

The newest version of Guild Wars Wiki Tools is currently being developed. The new release will introduce intelligent tagging; in its basic, it will analyze the page you are visiting and then automatically suggests possible tags that could be applied. If there are any special tags like {{user image}} or similar, it will notice you about that and all you need to do is to accept the changes. As speed is very important, it will do all this without disturbing you when you read a page, or when the page is loaded.

Multiple other features, some of them were requested in the past, will be introduced as well, including the {{inactive guild}} template. And especially the design will change (screenshots will follow).

So when will the new release released? I can't say that now, but it will definitely happen.

Guild Wars Wiki Tools

Guild Wars Wiki Tools is the original tool of the GWWT set. Based on GuildWatch, developed by Ale jrb, it is primarily used to tag pages with specific templates.

Current version
v1.1.5a (10:15, 9 October 2009 (UTC))
Supported browser
Gecko and WebKit rendering engine based browsers (Mozilla Firefox 2/3, Safari etc.), Opera 9.x, Microsoft Internet Explorer 7/8 (IE6 is experimental)
Screenshots
User space options, User space menu, Infobox Stub & Cleanup, Infobox deletion & move, Infobox speedy deletion, Image menu
Features
Tagging
Additional features
  • One-click button to see the last diff of an article
  • userspace links in the toolbox
  • user information buttons on user pages
  • optional watchlist sorting
Installation

To install Guild Wars Wiki Tools, simply add the following code to your monobook.js and you will automatically receive all following minor updates:

{{subst:User:Poke/GuildWarsWikiTools/install.js}}

If it does not show up after installation or if it displays an old version after an update, clear your cache by clicking CTRL + F5.

Configuration

The following configuration variables are available to be added to your monobook.js:

gwwtLoadAfter
Function. Will be executed automatically after GWWT has been loaded. Useful for executing custom additional code.
gwwtWatchlist
Boolean. If set to true, the watchlist is being sorted by namespace.
gwwtPortletPos
String. Set to an node id, to change the position of the GWWT portlet. The portlet will be displayed before the node with that id.

The following is an example, how the configuration could look like:

var gwwtWatchlist  = true;
var gwwtPortletPos = 'p-search';
var gwwtLoadAfter  = function()
{
    // do something
}

Note: With major releases the configuration might change completely.

Changelog
Version 1.1.4
public release. 21 December 2008
  • changed {{inactive guild}} and {{guild cleanup}} tags, to include an editors note
  • changed portlet position so its position is below the search portlet
  • introduced a new setting gwwtPortletPos to overwrite the position of the portlet
  • updated watchlist sorting to move log entries into the Special heading
  • updated speedy deletion reasons
GWWT automaticPatrol

Sysop only. Enables automated patrolling of pages. To enable add the following code to your monobook.js:

/**** Sysop automaticPatrol
 * (c) 2008 by Patrick Westerhoff [poke]
 */
addScript( 'User:Poke/GuildWarsWikiTools/automaticPatrol.js' );
hookEvent( 'load', function ()
{ gwwtAutomaticPatrol( false ); } );

Change the false to true to enable patrolling even by clicking normal links on Recent Changes or your Watchlist.

class PortletArea.js

Those who use GWWT can make use of the utility class, PortletArea. By using that class, it is quite easy to add custom portlets or custom links to existing portlets, such as the navigation portlet or the cactions portlet which represents the tab-display of the monobook style. The following is a class description:

  • constructor PortletArea ( String id, [ String title, Node nextNode ] )
    Creates a new PortletArea object pointing to a portlet with the unique html identifier id. If that id is not used yet, a new portlet is created with title as the portlet's title. If nextNode is specified, the new portlet is added before that node, otherwise it is added at the end of the navigation bar.
  • Node paObj.getArea ()
    Returns a reference to the portlet's div element.
  • Node paObj.addText ( String text )
    Adds a new text element, with text as the value, at the end of portlet and returns a reference to the created node.
  • Node paObj.addList ()
    Adds a new list element at the end of the portlet and returns a reference to the created node. List elements are used to hold portlet items.
  • Node paObj.addItem ( String id, String title, [ String href, String tooltip, Node listNode, Node nextNode ] )
    Adds a new list item element, with the unique html identifier id (can be null), to the portlet and returns a reference to the created node. The parameter title specifies the displayed title of the item. If href is not null a link is created targeting to href and tooltip is displayed when hovering over the link.
    By default, the new list item element is added at the end of the last open list object. If no list object is open, a new one is automatically created. You can overwrite this behaviour by directly specifying listNode as a reference to a list object inside of the portlet (as created by addList()) and/or by specifying nextNode as a reference of another list item object inside of the portlet. In this case, the new item is added before that node. If only nextNode is specified, the correct list element will be automatically determined.
GWWT ContributionCount

Bookmarklet. Firefox and standard-compliant browsers only. Counts all contributions of a given user and prints them, sorted by namespace. To use, enter the following code into your location bar and press enter.

javascript:addScript('User:Poke/GuildWarsWikiTools/ContributionCount.js');void(0);