Extension talk:UsabilityInitiative

Dev: bugreport on component UsabilityInitiative

=FAQ=

How to define the buttons?
It's not quite easy to add a new button, but its possible.

1. edit extensions\UsabilityInitiative\WikiEditor\WikiEditor.combined.min.js Add a, on line 8 after action:{type:'encapsulate',options:{post:"--~"}}} and thereafter your new button code as follows: 'nowiki': { labelMsg: 'wikieditor-toolbar-tool-nowiki',//Tooltip type: 'button', offset: [-70, -358], icon: 'button_nowiki.png', action: { type: 'encapsulate', options: { pre: " ", periMsg: 'wikieditor-toolbar-tool-nowiki-example', post: " " }	} }

2. The offset is important for the button image. The imagefile extensions/UsabilityInitiative/images/wikiEditor/toolbar/button-sprite.png is like an image-map and only partially shown. You need the right ccordinates of your button-picture and set them in the offset-option of step 1.

3. Defining language-options is done in the file: extensions\UsabilityInitiative\WikiEditor\Modules\Toolbar\Toolbar.i18n.php. Add there new lines in your language localization array with text like: 'wikieditor-toolbar-tool-nowiki-example'=>"This text is not parsed by mediawiki", 'wikieditor-toolbar-tool-nowiki'=>"NoWiki Button", //Tooltip

4. Now you have to say the hook, it has to parse the localization text (It does not with the whole array). Open extensions\UsabilityInitiative\WikiEditor\WikiEditor.hooks.php and scroll to line 185/186 and enter the following entries to the array: 'wikieditor-toolbar-tool-nowiki', 'wikieditor-toolbar-tool-nowiki-example',

5. Have fun with your new button.

How to define the selection tools?
How can I add and/or configure the select tools?

How to use the extension messages?
The extension define some interface messages, they are mainly there for localisation, which occurs on Translatewiki.net.
 * View all messages: Special:AllMessages - View existing:Special:PrefixIndex/MediaWiki:edittoolbar

Troubleshooting...
LocalSettings.php:

$wgDefaultSkin = 'monobook';

...

$wgPrefStatsTrackPrefs = array( 'skin' => 'vector', 'usebetatoolbar' => 1 );

I get the vector skin on Firefox and monobook on IE.

Switch external and internal link icons
I would switch them so the internal link button is listed first. --Subfader 16:38, 10 July 2009 (UTC)

ReadMe - Issue
The ReadMe is missing the most important line:

require_once("$IP/extensions/UsabilityInitiative/EditToolbar/EditToolbar.php");

But additional a short question: What is PrefStats for? There is no documentation either no explenation anywhere ?!?


 * 19493 - There is the report to authors about README topic. --almaghi 18:52, 16 July 2009 (UTC)

Editor Doesn't Display
I've downloaded the necessary files from SVN and placed them in my extensions folder. I have enabled the extensions via LocalSettings.php (I know i did it right because i copied from the README file. It lists that it is installed in my Versions page.  However  Editor will not display (currently using Mediawiki 1.15.1, I also have FCK editor installed. When i remove fck editor from localsettings.php the edit toolbar doesn't display and I recieve the following errors in edit.js:

In Firefox:

left is not defined http://myurl.com/skins/common/edit.js207 line: 51

in Internet Explorer 8:

this.style is null or not an object in edit.js  Line 51. --Kevin Danko 13:06, 10 August 2009 (UTC)

The extension requires a minimum of MediaWiki v1.16Alpha --mac77 23:08, 15 August 2009 (UTC)

=Talk=

New-Page Textarea broken in IE6
when following a red link to a new page, the empty editor window is broken and disrupts the layout. It wont accept the focus, too. The only workaround is to add some text via the toolbar (i.e. a link) and hit "preview"... the editor then acts normal. docMario, 15.08.2009 02:30CET
 * Addition: some characters of the textarea content always appear in the html content beneath the textarea. -- docMario, 15.08.2009 3:33CET

Doesn't display for me either MW1.15.1
I have the same problem, but I've not even had another editor installed. The edit toolbar is the old version, although Special:Version is showing the extension installed (I read the README). Edit: Well the extension page DOES say 1.16, so ignore this message I suppose. --Ciovala 22:57, 15 August 2009 (UTC)

Lots of new errors in r55291

 * 1) in IE6, the toolbar is not shown, the standard-toolbar is displayed instead. Although, by browsing through the source code I get the impression that's rather a feature, not a bug. --DocMario 13:13, 23 August 2009 (UTC)
 * 2) The toolbar takes almost 30 seconds to load (on a local server).
 * 3) when clicking on icons for 'table', 'link', or 'search' the browser hangs up and/or shows an out of memory error after 2-3 minutes.
 * 4) A new heading (chosen from the combobox) is inserted at the beginning of the text instead of the cursor position.

Wikificator tool
How to install in Edittoolbar button of wikificator tool ? The question is particularly in how to execute it's script by pressing button? --StereoMaster 13:47, 17 August 2009 (UTC)

"Download snapshot" not working
Special:ExtensionDistributor does not seem to know the UI-Extension. Is there another way to download all extension files at once? --129.206.90.2 00:55, 3 September 2009 (UTC)


 * I did it via svn, file by file manually :) --81.20.173.138 17:10, 4 September 2009 (UTC)


 * ...and why shouldn't you. Yet, a fix for the download would be much appreciated, folks. --Tickle me 01:54, 23 September 2009 (UTC)

Preference Statistics graph
I do not understand the bottom scale of the graph on the Preference Statistics special page. Does the point 0 represent now and the timescale going to the right goes back into the past? Or does 0 represent the time that preference statistics were activated and the scale going to the right goes forward in time? Is it possible to explain the answer on the preference statistics page, either by amending the label under the graph scale or the text at the top of the page? Lloffiwr 11:16, 20 September 2009 (UTC)

WikiEditor does not work
I just downloaded the trunk version of MediaWiki 1.16 alpha and added in the UsibilityInitiative extension trunk and after testing I have found that the enhanced editor (WikiEditor) does not work.

I began researching the UsibilityInitiative extension at the end of September and it seems that a few of the features have changed (ex: no more EditWarning and added in ClickTracking and UserDailyContributions). When I orginially tested the enhanced editor it was called EditToolbar and now it is referred to as WikiEditor, was there a reason for this change (or was it just a simple name change)?

Also, none of these new/changed features have been documented on the extension page. The instructions still refer to the WikiEditor as the EditToolbar (on the extension page and in the UsabilityInitiative.php file).

I hope that this is back up and running soon.

Thank you in advance.

--Dgennaro 18:03, 11 November 2009 (UTC)

+1 Here for MW 1.16 Beta 2 (Resolved)
I have a stable install of MW 1.16 B2. Installed UsabilityInitiative, updated localsettings and ran update.php. Cannot get the editor to work.

Special:Version shows usability and editor as installed. Extra options show up in user prefs. But clicking edit on any page still shows the old editor.


 * RESOLVED: Because of custom skin work I have done in my installation, when I upgraded I did not overwrite the Common skin folder. I have now done that and the issue is resolved and working! - Gomeztogo 23:37, 19 May 2010 (UTC)


 * What web browser are you using? Many older browsers won't work with the new editor. Releases/Babaco/Compatibility_Matrix --JeremyBicha 18:17, 4 May 2010 (UTC)


 * I have tested this on Chrome 5.x and Firefox 3.5.7 -- Gomeztogo 18:28, 4 May 2010 (UTC)
 * UPDATE - I just tried the latest from SVN and still unresolved. I have started going back and disabling all other extensions to see if there is a conflict, but that hasn't worked so far.  -- Gomeztogo 23:59, 5 May 2010 (UTC)


 * Ok, so this doesn't make any sense but this resolved the issue of the editor not showing up for me. I'm using 1.16 beta2 of mediawiki. I didn't want the Beta links to show so I set $wgOptInNeverShowPersonalLink = true; and the new editor immediately began appearing. I changed  $wgOptInNeverShowPersonalLink back to the default setting to see if it would go back to the old editor and the new editor stayed so I can't vouch for this being the solution but it is worth a try. -- James 10:58, 13 May 2010 (EST)
 * Having the same problem. Put the stuff in the extensions folder, then ran the update script, still not appearing for me when I try to edit a page! And i'm using the latest nightly dump version. Yet on the special pages version, it says its installed. --220.85.121.208 06:59, 2 June 2010 (UTC)
 * I figured it out, I had go to my preferences and turn on under editing, then check 'Enable enhanced editing toolbar.' How do I turn it on by default? I guess i'll have to look at the documentation more closely. --220.85.121.208 14:37, 2 June 2010 (UTC)
 * "How do I turn it on by default?" Just change the default settings by adding the following two lines to your LocalSettings.php:

$wgWikiEditorModules['toolbar']['global'] = true; // Enable the new toolbar for everyone $wgWikiEditorModules['toolbar']['user'] = false;// Don't allow users to turn the new toolbar on/off individually
 * --Figure002 01:59, 23 July 2010 (UTC)
 * Better yet, instead of those previous two lines, add this to LocalSettings.php:

$wgDefaultUserOptions['wikieditor-highlight'] = 1; $wgDefaultUserOptions['wikieditor-preview'] = 1; $wgDefaultUserOptions['wikieditor-publish'] = 1; $wgDefaultUserOptions['usenavigabletoc'] = 1; $wgDefaultUserOptions['wikieditor-template-editor'] = 1; $wgDefaultUserOptions['usebetatoolbar'] = 1; $wgDefaultUserOptions['usebetatoolbar-cgd'] = 1;
 * 1 = enabled, 0 = disabled. --Figure002 15:05, 23 July 2010 (UTC)

I followed all these suggestions and still doesn't work. Latest Firefox. 1.16 beta 3. --Douglas

Stats about gadgets
Hi,

This extension may be useful if it would also gives statistics about gadget usage (how many users use each gadget, ...). This would help telling which gadgets is useful, and which is not used (may be buggy, or may need improvment, ...).

--DavidL 11:13, 27 December 2009 (UTC)

Non-collapsible portlet?
How does one create a non-collapsible leftnav portlet, such as Wikipedia's "navigation"? --DoubleSuitedChris 07:33, 30 May 2010 (UTC)

Search and replace
On wikipedia's page, there is a search and replace on the toolbar, how do i enable that?

New buttons
I don't know about the other ways, but while searching for how to create new buttons I came across this page: http://en.wikisource.org/wiki/User:Alex_brollo/vector.js?match=pl

It might help you figure out how to add your own custom buttons by modifying the person's code. --Bluesoju 09:51, 15 June 2010 (UTC)

Download error
Subversion encountered an error:

svn: Working copy '/mnt/upload6/private/ExtensionDistributor/mw-snapshot/trunk/extensions' locked svn: run 'svn cleanup' to remove locks (type 'svn help cleanup' for details)


 * Give a link to download please!

Extension not working
I have installed 1.16 beta 3 successfully, the proper extensions (which even show in Special:Version), and have ran the update.php just for safe measures. Despite all of this, none of the extensions included work whatsoever. --Zwsteve 01:46, 14 July 2010 (UTC)

Same issue here, fresh copy of beta 3, fresh UI Extension, all features enabled in localsettings.php, and its doing absolutely nada...MrHand - 14:19, 14 July 2010 GMT

Works for on beta 1.16 beta 3. Are you sure you have corrcet settings in localsettings. e.g. for wikieditor:

$wgDefaultUserOptions['wikieditor-highlight'] = 1; $wgDefaultUserOptions['wikieditor-preview'] = 1; $wgDefaultUserOptions['wikieditor-publish'] = 1; $wgDefaultUserOptions['usenavigabletoc'] = 1; $wgDefaultUserOptions['wikieditor-template-editor'] = 1; $wgDefaultUserOptions['usebetatoolbar'] = 1; $wgDefaultUserOptions['usebetatoolbar-cgd'] = 1; 125.237.120.21 16 July 2010

Yup all there, not working. I've even got the optin and click tracking enabled without any effect at the moment. MrHand 13:37, 16 July 2010 (UTC)

Quick update, just downloaded last nights nightly build and extensions, dumped them on the wiki and it all works now. Thanks for the help folks :) MrHand 09:07, 19 July 2010 (UTC)

I still get the same subversion error. Is there another way to install the extension? --Ejcaputo 09:40, 19 July 2010 (UTC)

I finally got it to work by using svn directly (Windows 7): C:\web\www\wiki\extensions>svn checkout http://svn.wikimedia.org/svnroot/mediawiki/trunk/extensions/UsabilityInitiative --Ejcaputo 16:34, 21 July 2010 (UTC)


 * That method worked somewhat, but other parts of the extension like the Vector add-ons and WikiEditor still refuse to work.Zwsteve 14:59, 25 July 2010 (UTC)

I haven't enough privileges...
Installation 3.Run php maintenance/update.php from the command line (see update.php and also here)

I think it will create new table in my database,but I haven't enough privileges to use SSH or PHPSHELL. I have to Re-run the installer(When I update my MediaWiki,I also do like this).But It can not create new table of Usability Initiative.So I received a message “1146: Table 'acgpianodata.asi_prefstats' doesn't exist (localhost)”(acgpianodata is my database name,asi_is prefix）.

How can I create a new table of UsabilityInitiative without run update.php? Maybe someone can tell me the SQL statement? Thanks!--Xlsoul 04:33, 24 July 2010 (UTC)

I solve this issue because I found that there SQL statement in the UsabilityInitiative e.x.PrefStats.sql.I run them in phpadmin.There is no issue now.--Xlsoul 10:18, 25 July 2010 (UTC)

Dialog for tables doesn't appear
Our Wiki is the current Stable 1.16.0. The Option in the user preferences are activated. Has anybody an idea how to solve the problem?

No getting *any* toolbar (old style of WikiEditor) when viewing 1.16 Vector skin in IE6
I have just upgraded to 1.16.0 from 1.15.n and then installed the UsabilityInitiative extensions (0.1.1). Everything seemed fine - on my machine I used Firefox 3.n and IE8. Unfortunately a lot of my colleagues use IE6 (and can't change easily) - on these machines the WikiEditor does not display when a user is in the Vector skin and instead of the old Toolbar (as happens on Wikipedia in IE6) they get no toolbar at all; it's just a textbox with the wikitext and the usual buttons to save/preview at the bottom.

What values should I check? I followed the details in the extension install here exactly for the WikiEditor and Simple Search parts (I did not apply the other sections relating to Click Tracking/OptIn/PrefStats/UserDailyContribs).

I appreciate that in IE6 it won't be the fully-fledged toolbar, but a lot of the users here need at least the old method as they are not terribly technical / happy dealing with wikitext (even though I encourage them!)

Neil 83.244.174.157 16:18, 4 August 2010 (UTC)

Pasting text in WikiEditor makes text cursor go haywire
Hi,

I just installed the UsabilityInitiative extension on our newly upgraded MediaWiki and when I'm pasting text while editing (or creating) a page with the WikiEditor enabled, the text cursor teleports to somewhere else in the text and most of the time the formatting is broken (i.e. spaces and line breaks inserted everywhere in the text). Anyone else is having this problem? When I disable the WikiEditor plugin, everything works like a charm. When enabled, the plugin itself works, but I also get this pasting problem when I'm on Firefox.

Here is my current setup:
 * Browser: Mozilla Firefox 3.6.8 rv:1.9.2.8 (in French)
 * Computer: Windows 7 Professional
 * Server: Windows Server 2008 Standard SP2 32bit
 * MediaWiki 1.16.0
 * PHP 5.3.2 (cgi-fcgi)
 * MySQL 5.1.48-community
 * Installed extensions:
 * FileProtocolLinks
 * SyntaxHighlight (Version 1.0.8.6)
 * wikicalendar (Version 1.16)
 * UsabilityInitiative (Version 0.1.1)
 * Vector (Version 0.2.0)
 * WikiEditor (Version 0.2.0)

I experienced this problem using Firefox 3.6.8 on Windows 7 and on Linux (CentOS 2.16.0). When tested in Internet Explorer 8, no problem at all, so I suspect the problem is with Firefox. I also tried in Chrome 5.0.375.125: when pasting, I must click on the Edit box to be able to paste again, but since I'm not a chrome user, I don't know if this is normal or not.

Thanks. Bibz 19:15, 5 August 2010 (UTC)


 * Looks like commenting the  call in the plugins.combined.min.js file (around line 454) did the trick. According to the comments written in plugins.combined.js, this call has been made for IE, but it messes up Firefox for some reason. Maybe some code could be added to check if the browser is indeed IE and if it's the case call the paste event but does nothing if the browser is not IE. Anyway, now at least I can edit my pages properly in Firefox. Bibz 19:00, 18 August 2010 (UTC)

Michael-RX 13:00, 25 August 2010 (UTC) I have a similar problem but just with Internet Explorer 8. If a paste or insert a f.e. link over the toolbox the new inserted text is always inserted at the first line of the text. Not at the current position as expected. If i try the same on this mediawiki site then the cursor stays as expected.

My current setup
 * MediaWiki 1.16.0 (r22)
 * PHP 5.3.3 (cgi-fcgi)
 * MySQL 5.1.50-community
 * Vector (Version 0.2.0) (r22)
 * WikiEditor (Version 0.2.0) (r22)

Any glue?


 * Have you tried to comment the line I mentioned? Bibz 18:17, 25 August 2010 (UTC)

WikiEditor not working
I installed UsabilityInitiative extension and enabled WikiEditor in LocalSettings.php. Then I ran update.php script. But the editor doesn't work. I checked on IE8 and Firefox3.6.8, but It doesn't work on both. I tried to debug javascript by using Firebug. Then following bug was displayed.
 * On IE, it appears. But the textbox of editor disappears as soon as loaded.
 * On Firefox, it appears first. But all of the page disappears when loading is finished. So, nothing is diplayed finally.
 * elem.documentElement is null
 * http://127.0.0.1:8080/MediaWiki/skins/common/jquery.min.js?270
 * Line 237

My setting is following.

My server environment Software version MediaWiki  1.16.0 PHP 	   5.3.2 (apache2handler) MySQL 	   5.1.30-community
 * Windows XP SP3
 * Apache 2.2.14
 * This is a local server. I access to wiki from same computer.

Installed Extensions ParserFunctions 1.1.1 UsabilityInitiative 0.1.1 Vector 0.2.0 WikiEditor 0.2.0

some of my LocalSettings.php require_once( "$IP/extensions/UsabilityInitiative/WikiEditor/WikiEditor.php" );
 * 1) WikiEditor (Toolbar, Toc, Preview, Highlight)

$wgWikiEditorModules = array(	'highlight' => array( 'global' => false, 'user' => true ),	'preview' => array( 'global' => false, 'user' => true ),	'toc' => array( 'global' => false, 'user' => true ),	'toolbar' => array( 'global' => false, 'user' => true ), ); require_once("$IP/extensions/UsabilityInitiative/Vector/Vector.php"); $wgVectorModules = array(	'collapsiblenav' => array( 'global' => true, 'user' => false ),	'collapsibletabs' => array( 'global' => true, 'user' => false ),	'editwarning' => array( 'global' => false, 'user' => true ),	'simplesearch' => array( 'global' => true, 'user' => false ),	'expandablesearch' => array( 'global' => true, 'user' => false ), ); And I enabled all WikiEditor modules in my user preference. Is it a bug? Or my configuration misstake?
 * 1) WikiEditor config

Oh, sorry. I forget adding signiture. --Yuu.taka 17:22, 10 August 2010 (UTC)

Having problems running update.php and WikiEditor not working
I just upgraded to 16.0 and I am trying to install the UsabilityInitiative Extension. When I try to run update.php, I get a syntax error. I am running php 5.2.8. Does anyone know what the problem might be?

The only part of the extension that I want to use is the WikiEditor. Do I need to run update.php for it to work since it doesn't modify or add any database tables? If I don't need to run it, why isn't the WikiEditor working?

Any help would be much appreciated!

RenaR 05:31, 11 August 2010 (UTC)

Creating new help Sections
I want to create a new help section, My site uses a lot of templates and some are regularly used and I want to add them to a new help section in the Wikieditor. What pages will i need to create and which do i need to edit? Site is www.aionopedia.info


 * Here is what I did. I don't know if it is correct, but it did the trick. You'll need to change 3 files: WikiEditor.hooks.php, WikiEditor.combined.min.js and Toolbar.i18n.php. These files are located in the UsabilityInitiative/WikiEditor/ and UsabilityInitiative/WikiEditor/Modules/Toolbar folders of the extension. I renamed the original WikiEditor.combined.min.js to WikiEditor.combined.min.js.old and renamed WikiEditor.combined.js to WikiEditor.combined.min.js. I think they are the same file, but the min one is just not formatted at all and hard to read compared to WikiEditor.combined.js. Anyway, here's the modifications I've made:
 * Add this line to WikiEditor.hooks.php where the other help pages are declared (around lines 267 to 277):


 * Add these lines to WikiEditor.hooks.php at the end of the help content declaration (around line 335). Change the lined to make them reflect the name of the template (in this example the template was done).


 * Repeat the previous step for every template you want to add to your new Help page
 * Add the following lines to Toolbar.i18n.php (for English, it's around line 214):


 * Repeat the previous step for every template. You'll need to change the values of each 3 lines to display the correct information. For the result value, I had to look at the source code of a page containing the desired template to know what HTML code is used to display said template.
 * Then, finally, add these lines to WikiEditor.combined.min.js, in the pages part of help section (around line 714):


 * You will need to have a row for each template you want to add to the help page. In this example I wrote 2 rows: Done and Not Done.
 * That's it. Even though it's possible to add pages to the extension, I think it's really a pain to do it. Maybe the extension could have something that helps add pages to itself? Anyway, if you have any problems, just ask. Bibz 13:30, 16 August 2010 (UTC)

Preview tab not working in Safari and Opera (and Chrome on Mac)
We're running MW 1.16 with UsabilityInitiative (Version 0.1.1).

In the browsers listed below, when we click on the preview tab, the loading process hangs and just spins forever.

This happens in:


 * Safari Version 5.0.1 (mac)
 * Opera 9.64 (on XP)
 * Chrome 5.0.375.126 for mac

Other browsers all seem fine, including Chrome 5.0.375.126 on XP.

Any ideas? Is this a bug?

122.58.97.239 20:55, 16 August 2010 (UTC)


 * I tried with Opera 10.60 on Windows 7 and I got the same bug. Bibz 20:53, 17 August 2010 (UTC)

what does $wgDefaultUserOptions['wikieditor-highlight'] = 1; do
by toggling on and off the various features, I saw what each one did, except for wikieditor-highlight. I can't see any change, and there's no documentation. So, what does it do? Ethan1701 11:54, 1 September 2010 (UTC)

WikiEditor questions
Hello, I tried this extension (r69578 snapshot and trunk versions) on MW1.16 and now I've got some questions.

1) It's very odd thing but I see html tags in WikiEditor and not the wiki-markup tags. Is there any way to enable wiki-markup tags and to disable its conversion into html tags?

2) I still have to use FCKeditor for my newcomers who know nothing about html- or wiki-markup. My users could switch between FCKeditor and wiki's standard one now. But after installation the WikiEditor they can't. Why? Thank you for your work.

--Amoeba 11:18, 6 September 2010 (UTC)

Advance WikiEditor Toolbar
Does anyone have an advanced toolbar already configured that I can download. My eyes are crossing trying to add buttons to the toolbar manually. I can use most of the buttons, including those that have opening and closing tags with text in the middle, such as for centering text.

--Bro. Ignatius Mary 12:21, 17 September 2010 (UTC)