Add/remove buttons for multiple input form do not work

If you are having problems with GuMax, post here.
Post Reply
User avatar
magdan
Rank 0
Rank 0
Posts: 2
Joined: November 17th, 2011, 11:10 am

Add/remove buttons for multiple input form do not work

Post by magdan »

Dear all

I defined a form to create some "techno news":

Techno news form:

Code: Select all

{{{info|partial form|edit title=Add or change news}}}
{{{for template|News|label=Techno news|multiple}}}
'''News:''' {{{field|1}}}
{{{end template}}}
using the following template:

News template:

Code: Select all

Techno news: [[News::{{{1}}}]].
The result is OK with the monobook skin: I get a "Add another" button and when I click it, a box appears with my "News" field and a "Remove" button on the right side. When choosing my default GuMaxDD skin the "Add another" button also appears but clicking on it has no effect at all.... :(
I can see in the GuMaxDD.php file that I use version 1.1.

Thanks for your help !
User avatar
magdan
Rank 0
Rank 0
Posts: 2
Joined: November 17th, 2011, 11:10 am

Re: Add/remove buttons for multiple input form do not work

Post by magdan »

I found the solution to the problem on MediaWiki:
http://www.mediawiki.org/wiki/Extension ... patibility
----
SF 2.0+ & GuMaxDD skin compatibilityIt has been shown that in some skins (such as GuMax) some features (such as autocomplete) do not work in SF 2.0+ since the extension no longer uses YUI. The issue here is that 2 references to jQuery are inadvertently created. it has been recommended to remove the line in the skin's PHP file that includes the jQuery library reference. However, when using GuMaxDD (GuMax skin with dropdown menu bar), this will invariably break dropdown menus in all pages except for form pages. Instead (based on my experience), you would want to remove the jquery include from the extension, not the skin. This would be appropriate for wiki's that do not encourage or allow users to change skins in their user preferences. To do so, you would want to comment out the following clause (lines 202-206) in SF 2.0.4):

Code: Select all

if ( method_exists( 'OutputPage', 'includeJQuery' ) ) { $wgOut->includeJQuery(); } else { $scripts[] = "$sfgScriptPath/libs/jquery-1.4.2.min.js"; }
You may also want to move the jQuery include line in the skin before any other jQuery plugin includes/function calls and after all CSS references. Since there may very well be a number of skins that rely on jQuery, perhaps there could be a way to store a blacklist of skins as a global variable which the extension can check before including jQuery. --Mtyeh411 21:21, 23 November 2010 (UTC)

Hi - removing the jQuery call from SF itself sounds like good advice; thanks. I've really only heard of two skins that include jQuery: GuMax (or the GuMax "family" of skins), and OntoSkin. And OntoSkin comes with a package that includes its own (older) version of SF, so it's really only GuMax that's the issue. But I'll update the documentation. Yaron Koren 15:15, 24 November 2010 (UTC)
---

Magdan --
User avatar
Paul
Development Team Leader
Development Team Leader
Posts: 1132
Joined: October 20th, 2007, 2:23 pm

Re: Add/remove buttons for multiple input form do not work

Post by Paul »

Thanks for sharing.......... It might be a good idea to find an alternative drop down script.
Post Reply