Extension talk:Semantic Forms Inputs

From MediaWiki.org
Jump to: navigation, search
Start a new discussion


Thread titleRepliesLast modified
Menuselect Warnhinweis: Eine Teilabfrage enthält eine ungültige Bedingung207:53, 15 October 2014
"datepicker"022:22, 4 August 2014
Datepicker: Format in Form ok but saved value displayed in wrong format815:17, 1 July 2014
SFI not working -- Giving error015:42, 30 May 2014
Dynamic default value (now) possible?914:53, 6 May 2014
Menuselect - can you alter the drop-down menu width?307:12, 3 May 2014
pipe characters in input text119:48, 23 April 2014
Javascript error using input type=datapicker108:43, 14 February 2014
Support default=now108:42, 14 February 2014
Sort order for "two listboxes"?316:54, 28 January 2014
Conditional Regular Expression112:58, 16 December 2013
Forms gone114:15, 20 November 2013
box size for "two listboxes"016:33, 31 October 2013
jQuery data undefined error and 2 Listbox Appearance713:34, 6 September 2013
datetimepicker is not supported in multiple-instance templates600:18, 12 June 2013
No year scrolling517:37, 28 May 2013
Menuselect1513:09, 24 April 2013
Disable selecting dates from future120:52, 14 January 2013
Slashes207:33, 27 November 2012
datepicker with german user localisation doesn't work correctly321:36, 1 November 2012
First page
First page
Previous page
Previous page
Last page
Last page

Menuselect Warnhinweis: Eine Teilabfrage enthält eine ungültige Bedingung

Edited by author.
Last edit: 09:32, 14 October 2014

Trying to use the MenuSelect https://www.mediawiki.org/wiki/Extension:Semantic_Forms_Inputs#Examples_4 as outlined in the example

{{{field|Part of|input type=menuselect|structure= {{#ask: [[Part of::+]]{{!}} format=tree{{!}} parent=Part of }} }}}

I get the error message: Warnhinweis: Eine Teilabfrage enthält eine ungültige Bedingung the simple example

{{{field|foo|input type=menuselect
* Item 1
** Item 11
** Item 12
* Item 2
** Item 21
** Item 22

works as expected. Neither

'''Thema:''' {{{field|Thema|input type=menuselect|structure={{#ask: [[Category:BITPlanStandard]] {{!}} ?nr {{!}} format=tree {{!}} parent=nr {{!}} limit=70 }} }}}


'''Thema:''' {{{field|Thema|input type=menuselect|structure={{#ask: [[Category:BITPlanStandard]] {{!}} format=tree {{!}} parent=nr }} }}}


'''Thema:''' {{{field|Thema|input type=menuselect|structure={{#ask: [[Thema::+]]{{!}} format=tree{{!}} parent=Thema }} }}}

work - all give the same error message.

All these ask queries used on their own work as expected.


  • MediaWiki 1.23.5 (a80a0a2) 19:06, 13. Okt. 2014
  • Semantic Forms 2.8 (8bdcec3) 21:31, 6. Okt. 2014 GPL-2.0+ Ermöglicht Formulare zum Hinzufügen und Bearbeiten semantischer Daten Yaron Koren, Stephan Gambke und andere
  • Semantic Forms Inputs 0.9.0 alpha (329a4b7) 19:14, 27. Aug. 2014 GPL-2.0+ Ermöglicht verschiedene zusätzliche Eingabearten für Semantic Forms Stephan Gambke und andere
  • Semantic MediaWiki 2.0 GPL-2.0+ Ermöglicht es, das Wiki zugänglicher zu machen – für Menschen und Maschinen (Dokumentation) Markus Krötzsch, Jeroen De Dauw, James Hong Kong und andere
  • Semantic Result Formats 1.9
Seppl2013 (talk)08:12, 14 October 2014

The example is wrong ... {{!}} should not be used but the verbatim | So e.g.:

'''Thema:''' {{{field|Thema|input type=menuselect|structure={{#ask: [[Category:BITPlanStandard]]  | format=tree | parent=nr | limit=70 }} }}}

works. I feel stupid :-) Please fix the example so other's won't get into this feeling, too ...

Seppl2013 (talk)09:08, 14 October 2014

Indeed? Could be something changed with latest changes in Semantic Forms. Anyway, fix it yourself, it's a wiki.

F.trott (talk)07:53, 15 October 2014


for "input type=date" works the next:


but, for "input type=datepicker" does not works "default=now"

how can i do that datepicker field prints the current date?, 4 August 2014

Datepicker: Format in Form ok but saved value displayed in wrong format

Dear all,

I'm using the Datepicker from Input formats in a german installation. In the Form I defined "date format=dd.mm.yy" and when using the picker everything is fine. But after saving the form data (I understand that the dates are saved in format YYYY/mm/dd anyway) and calling the result wiki site the date is also shown in YYYY/mm/dd format.
The strange thing is that I already have a similar setup of a Form that is also utilizing the datepicker and this works perfectly well. The date format during entering/editing in the datepicker is in dd.mm.yy format and after saving the dates on the result wiki page are also displayed in the correct dd.mm.yy format.
I could not find any differences regarding the date form fields and template definitions in both cases - therefore I don't have a clue what is going wrong here...

Does anybody have some suggestions?
Many thanks!

Sochin67 (talk)15:40, 22 March 2013

You should use the #time parser function from Extension:ParserFunctions. I don't know, why one wiki works while the other doesn't. Look at the source of the wiki pages to see if they really are the same.

F.trott (talk)20:35, 26 March 2013

The help states, that one can only format the field in the form, but the value send to the template is alsway YYYY/mm/dd, for easy storage. Well, I find it not easy in any case, for now I have to change the display of the value at every instance again, which is all, but easy.... Would be nice, if one could globally, or per property, define a standard output format.

Heinrich krebs (talk)13:24, 12 May 2014

The values are formatted by a form, so it is not necessary to change each and every page. Just change the form (format the date using the #time parser function).

F.trott (talk)13:33, 12 May 2014

Could you post an example, please ? I edited the template, that is filled by the form, so the values were reformatted to the way I want them to be, that kinda works... Still, I find it not elegant, and can't see the reason, why the format in the form isn't the same as the format sent to the template and ultimately is stored in the property.

Heinrich krebs (talk)15:23, 12 May 2014

Yes, sorry, editing the template is what I meant.

The problem with other date formats is, that they are ambiguous and may not be interpreted correctly (or not recognized at all) by SMW. So you should store the date in the property in the yyyy/mm/dd format and display it in whatever format you prefer using the #time function.

F.trott (talk)15:27, 12 May 2014

SFI not working -- Giving error


MediaWiki 1.21.2
PHP 5.3.17
MySQL 5.5.33
Lua 5.1.5
Semantic Forms Version 2.7
Semantic Forms Inputs Version 0.7

I have tried SFI 0.9alpha with the same results.

I keep getting the following error:
Ext.semanticforms.main: TypeError: Cannot read property ‘initFunctions’ of undefined

I have tried different browsers and different accounts, updated extension file permissions, etc with no luck. When I use F12 in Chrome is makes a reference to the Vector skin but I'm not sure what to make of it. Can anybody help me?


Clifford15:41, 30 May 2014

Dynamic default value (now) possible?

With SF's input type=date or datetime it's possible to specify 'default=now', and it'll fill in the current time, is this also possible with date(time)picker? 'default=2014/10/05' in the form definition does not work, since the #time parser functions does not get evaluated.

Patrick Nagel13:48, 9 March 2011

I'm afraid it is not possible with either of them. The default value is handed down to the input type in the same parameter as the current value, there is no possibility to distinguish between them so I can't decide when to parse and when not. The solution lies with SF here. You might vote on this or this bug or (more effectively) discuss it with Yaron directly.

F.trott20:35, 9 March 2011

It's not clear to me that this requires any change from SF - it might just need a fix in SFI. F.trott and I talked about the issue "offline", but now I don't remember what the conclusion was.

Yaron Koren16:00, 11 March 2011

I do. :)

The point is, SFI could parse the current/default value given as a parameter to the input. But then it would also parse any user input a user might have done earlier. E.g. lets say it would indeed parse the value. Along comes some user thinking that "{{#time:...}}" would be a good thing to put into that field - would result in a valid date after all. This user would fully and rightly expect that "{{#time:...}}" appears verbatim in the page. It even would after the first edit. Then on the second edit the datepicker would parse that string and save it, i.e. it would replace the parser command by a static value.

F.trott22:49, 11 March 2011

Patrick, could you try updating to the last SVN version of SF and using default={{#time:Y/m/d}}? (You will need Extension:ParserFunctions if you don't have it yet.) The "default" parameter should get parsed now. It's still brand new, so any bug reports would be welcome.

F.trott22:57, 15 March 2011

just tried that, but the date doesn't get parsed inside the form field. I'm using SF 2.2.1, SFI 0.4.2 alpha, parser functions 1.4.0, 8 August 2011

Hmm, should work.

What exactly do you specify as the default and what is displayed in the form?

And does it work if you use a different input type, e.g. text?

F.trott07:34, 9 August 2011

Using default with the parser worked for me. Remember that if you use a parser within a field declaration make sure it is not the last parameter specified, or if it is, place the 3 field closing curly braces on the next new line, otherwise it will break the field; for example:

  • WRONG:
    {{{field|bulletin_date|mandatory|input type=datetimepicker|default={{#time:Y/m/d}}}}}
  • RIGHT:
    {{{field|bulletin_date|mandatory|default={{#time:Y/m/d}}|input type=datetimepicker}}}
  • RIGHT:
{{{field|bulletin_date|mandatory|input type=datetimepicker|default={{#time:Y/m/d}}


   Thorncrag  19:12, 10 October 2011

That bug is mentioned in the documentation - if it's any simpler, you don't even need a newline, you just need a space (like "}} }}}").

Yaron Koren21:12, 10 October 2011

Menuselect - can you alter the drop-down menu width?

Menuselect allows you to set the maxlength of the input, and the size of the field itself.

However, the drop-down menu seems to be set at about 20 characters wide. It means that, with long menu items, they wrap-around and you have a very long, thin, drop-down menu for only about 20 items.

Would it be possible for it to set the menu width to the width of the longest entry?

Alternatively, is there a way of setting the drop-down length wider?

Fustbariclation (talk)

Fustbariclation (talk)09:14, 30 April 2014

Coincidently there is a current discussion on this on the smw user mailing-list. Cheers

[[kgh]] (talk)12:21, 30 April 2014

Thank you for the pointer - but it's not a coincidence - at least it is, but not an accidental one because the question there is also from me.

I thought I'd put the answer here for anybody coming later:

It turns out that this is a bug with Safari (version 7.0.3) - the menu works perfectly well on Firefox (version 28.0). That is, the drop-down menu is wide enough and there is no wrap-around, so it looks fine.

I've submitted a bug report to Apple about the problem with Safari.

Fustbariclation (talk)03:12, 2 May 2014

I thought that it might be you, but one never knows. Just yesterday me and another user posted the very same question to something out of the blue. So ... :) I am glad that it was possible to track down the cause of the issue and I hope that Safari does its part soon, too. Cheers

[[kgh]] (talk)07:12, 3 May 2014

pipe characters in input text

hello there i have a form where users can input text (paste e-mails that can contain all kinds of characters) I was able to escape all wiki markup characters using #replaceset function but there is one problematic one, which is pipe (|). Code datatype cannot do with it anything either. Any ideas how to escape pipes?, 23 April 2014

It might be worthwhile for those text emails to go into a form "section" (using the {{{section}}} tag), instead of a form "field" - there's a lot more flexibility there.

Yaron Koren (talk)19:48, 23 April 2014

Javascript error using input type=datapicker

I've installed SFI development version on MW 1.19 and SMW 1.7 and SF 2.5.2.

In the form I use:

{{{field|Startdatum gepland|property=Startdatum gepland|input type=datepicker}}}

It appears a textbox in the form and i get the followin Javascript error:

Uncaught TypeError: Cannot read property 'regional' of undefined TestCluster:399
(anonymous function) TestCluster:399
fire load.php:14
self.fireWith load.php:15
jQuery.extend.ready load.php:6
DOMContentLoaded load.php:12
Toine Schijvenaars (talk)18:24, 28 May 2013

I never responded to this, sorry! Is it still an issue?

F.trott (talk)08:43, 14 February 2014

Support default=now

For datepicker please!

David Mason (talk)16:19, 7 July 2013

Sort order for "two listboxes"?

Is it possible to force a sort of the contents of Two Listboxes? I've tried going back and changing the order of the allowed values for my property, but the sort order of the listboxes never changes. Thanks.

Lsilverman (talk)03:33, 28 January 2014

I think it should be possible to do that using the plain "values" parameter (i.e. not one of the "values from..." parameters). You could try using an ask query, something like values={{#ask: ... }}. Of course you then face the problem of sorting that ask.

If you already specify allowed values with your properties the simplest solution might be to just explicitly list the allowed values by hand in your form. Or - if you have many forms - to put the list of allowed values in a template. All not very comfortable or elegant, I know.

F.trott (talk)16:16, 28 January 2014

Am I correct that specifying a preferred sort order isn't supported on any of the input types?

Lsilverman (talk)16:53, 28 January 2014

Yes, you are correct.

F.trott (talk)16:54, 28 January 2014

Conditional Regular Expression

Hi I'm sure I'm missing something simple, but here's the problem: I have some optional fields that a user can elect to fill out or not, but when they are filled out they need to be limited to the pattern they can enter. But if I set a regular expression for that field it shows an error if it is not filled out. The mandatory setting in Semantic Forms recognizes if statements -- is there away with semantic inputs to write a regular expression that's conditional? I'm sure I'm over looking something simple, because that's generally the case, but any guidance here would be helpful. Thanks

Christharp (talk)04:01, 12 December 2013

The input is matched against a JavaScript style regexp. Maybe this helps: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions

In principle it should be as easy as wrapping your whole regexp in parenthesis and appending a question mark.

F.trott (talk)12:57, 16 December 2013

Forms gone

Hello team,

After a dozen upgrades and a fresh mediawiki install I've lost all my forms. I unable to locate 'm in backups. Where are the forms saved to?


T, 18 November 2013

Forms are stored as pages in the Forms namespace.

F.trott (talk)14:15, 20 November 2013

box size for "two listboxes"

It would be nice if we can specify the size of the two listboxes rather than playing with css... Thanks in advance., 31 October 2013

jQuery data undefined error and 2 Listbox Appearance

I installed this extension mainly for the two listboxes but couldnt get it to work properly.

1) In my semantic form, I created a field with input type=two listboxes and when I preview this created form, this is showing this error:

ext.semanticforms.main: TypeError: jQuery(...).data(...) is undefined

The above error shows only when I preview the form in the "CreateForm" page but it seems to work when I actually try to fill-in the form. I am using MW 1.21 and I downloaded the development version of your extension from Git.

2) The listbox display seems different in the picture you had given in your extension page to what I see on my installed version. For example, the 2 listboxes are right next to each other but in your picture it is displayed nicely since the listboxes are separated and displayed with an arrow in between them. How can I get that appearance for these 2 listboxes?, 4 September 2013

Hi! I'm the developer of two listboxes, I'll try to help. First please try to add &debug=true to the URL and provide the full error message with problematic line numbers.

Katkov Yury (talk)11:51, 4 September 2013

Thank you Katkov.. Thank you for developing this input method. :)

Okay, I tried adding &debug=true to the URL but nothing happens. Could it be that this error only shows when I click on the "Preview" button when I am Editing the Form and not in the actual URL? For instance, when I add &debug=true directly to the form url like www.url.com/wiki/index.php/Form:xyzForm&debug=true, then it shows the "There is currently no text in this page. You can search for this page title in other pages, search the related logs, or edit this page" message since its trying to create a new page. When I click on Edit Form, and then click preview, that is the time the error shows. So when I try adding &debug=true to the URL that shows when viewing the preview like this: wiki/index.php?title=Form:xyzForm&action=submit&debug=true or wiki/index.php?title=Form:xyzForm&debug=true&action=submit, then it just shows the form edit page without any previews or errors. So sorry couldnt be of help there since I couldnt get the full error message with problematic line numbers. Are you maybe able to reproduce this by trying to edit the form that has the 2 listboxes and then click on Preview button? The error message shows in 2 pop-up boxes when the preview form page is loaded:

Dialog 1 says: "ext.semanticforms.main: TypeError: jQuery(...).data(...) is undefined" with OK button,

Dialog 2 says: "ext.semanticforms.main: TypeError: jQuery(...).data(...) is undefined" along with a checkbox in the next line that says "Prevent this page from creating additional dialogs" and then the OK button.

But like I said before, although these errors shows when I preview the form edit page (note it happens only when I edit the actual form and not the article that was created based on the form), the form actually works when creating an article using it. So not sure what could be the cause...

And, any suggestions on how I can style these listboxes like I mentioned in (2) above? Are the listboxes showing close to each other because of the other error or is this how its supposed to be? Do you have a working example by any chance?


Alien Time (talk)13:19, 4 September 2013

Can you open it in Chrome and press F12? Pick Console in the tabs and tell what is said there with debug=true.

Katkov Yury (talk)13:36, 4 September 2013

ah...This is what it says:

TypeError: list[firingIndex] is undefined

load.p...131930Z (line 12)

....split(core_rspace),function(_,flag){object[flag]=true;});return object;}jQuery....

And when I click on Line 12, it highlights this:

function doScrollCheck(){if(!jQuery.isReady){try{top.doScroll("left");}catch(e){return setTimeout(doScrollCheck,50);}jQuery.ready();}})();}}}return readyList.promise(obj);};jQuery.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(i,name){class2type["[object "+name+"]"]=name.toLowerCase();});rootjQuery=jQuery(document);var optionsCache={};function createOptions(options){var object=optionsCache[options]={};jQuery.each(options.split(core_rspace),function(_,flag){object[flag]=true;});return object;}jQuery.Callbacks=function(options){options=typeof options==="string"?(optionsCache[options]||createOptions(options)):jQuery.extend({},options);var memory,fired,firing,firingStart,firingLength,firingIndex,list=[],stack=!options.once&&[],fire=function(data){memory=options.memory&&data;fired=true;firingIndex=firingStart||0;firingStart=0;firingLength=list.length;firing=true;for(;list&&firingIndex<firingLength;firingIndex++){if(list[firingIndex].apply(data[0],data[1])

Alien Time (talk)14:40, 4 September 2013

Another time I reloaded this error showed up too (although most of the time, it shows error in line #12 except for this time):

TypeError: jQuery(...).data(...) is undefined

load.p...3128Z&* (line 32)

...noexecute){var input=this;jQuery(function(){initFunction(input.attr("id"),param)...

Line 32 is this:

initFunction,param,noexecute){if(!this.attr("id"))return this;if(!jQuery("#sfForm").data("SemanticForms")){setupSF();}if(!jQuery("#sfForm").data("SemanticForms").initFunctions[this.attr("id")]){jQuery("#sfForm").data("SemanticForms").initFunctions[this.attr("id")]=new Array();}jQuery("#sfForm").data("SemanticForms").initFunctions[this.attr("id")].push({initFunction:initFunction,parameters:param});if(this.closest(".multipleTemplateStarter").length==0&&!noexecute){var input=this;jQuery(function(){initFunction(input.attr("id"),param)});}return this;};jQuery.fn.SemanticForms_unregisterInputValidation=function(){var sfdata=jQuery("#sfForm").data("SemanticForms");if(this.attr("id")&&sfdata){for(var i=0;i<sfdata.validationFunctions.length;i++){if(typeof sfdata.validationFunctions[i]!=='undefined'&&sfdata.validationFunctions[i].input==this.attr("id")){delete sfdata.validationFunctions[i];}}}return this;};jQuery.fn.SemanticForms_unregisterInputInit=function(){if(this.attr("id")&&jQuery(

Alien Time (talk)14:47, 4 September 2013

datetimepicker is not supported in multiple-instance templates

Placing a datatimepicker field inside a multiple-instance template does not seem to be supported: When modifying the date of any of the added instances, it always updates the value of the first one. http://scratchpad.referata.com/wiki/Form:Datetimepicker (to verify behavior copy in a site with Semantic Forms Inputs installed)

Xavier Atero (talk)18:12, 8 December 2012

I have a problem like this. If the form with multiple instance has more than one datepicker, only the first can be used.

Fernando Carpani (talk)13:28, 17 December 2012

Menuselect also not supported in multiple-instance templates. It prints the menu structure instead of creating a menu.

Protnet (talk)20:36, 27 December 2012

Does the development version work?

I meant to release that for a while now, but if it is still buggy, there is probably no point.

F.trott (talk)20:48, 14 January 2013

I just tested this with the current 0.7 alpha (30d00f0) for the datepicker input format. The problem is still persistent. A fix would be cool.

[[kgh]] (talk)21:59, 24 January 2013

Just tried it again using SF 2.5.2 (latest development version) and MW 1.20 and MW 1.22alpha (latest development version). It worked just fine for both menuselect and datepicker.

F.trott (talk)19:57, 9 May 2013

No year scrolling

Hi, I've just installed Inputs and I'm having a problem with the datepicker. The year selection seems to be fixed in a 10 year period either side of the default (or last selected) year. Scrolling thru to years not appearing in the list is not possible. MW 1.18, SF 2.3.1, SFI 0.5, SMW 1.6.1.

Fault is not dependednt on the "first date =" variable

I've tried IE on XP an Firefox on Mac OSX, same result.

Is it a bug or a problem with my settings somewhere?

Cheers - Scott

Scott D00:45, 11 December 2011

You are right. What would be the expected behaviour, though?

F.trott10:07, 11 December 2011

Sorry for the delayed reply, been rather busy of late...

I would expect it to keep scrolling back/forward through the years until you stopped pressing the up or down arrow. One of the forms I am using it in is to input a vehicle's year of manufacture. When someone begins to fill out the form and selects the year then they can only scroll back as far as 2001. This may confuse some into thinking that they cannot enter a date prior to that.

Scott D13:15, 19 December 2011

I would like it to work a bit differently than you proposed (e.g. like this, preferably with a click-and-hold feature for fast forward/backward), but I agree, that something like that would be a really nice feature. The problem is, it would require a change to the jQuery datepicker code, which is out of the scope of this extension. I will note it as a feature request, but better don't hold your breath on it.

If you are really intent on having this, you would have to drive it. I.e get someone at jqueryui.com to implement your feature and then kick me again to use it.

(What I probably could do is give you some option where you could set the years shown in the dropdown.)

F.trott13:53, 19 December 2011

Either way would work. I'd be surprised if it's hard to fix the existing control though. When you click on the year control, if you select the earliest year in the list the control disappears and shows the year selected. The next time you click on the control the year previously selected is centred in the list and you can go back another ten years. The control can eventually be 'hacked' to get back to the year that you want, you just can't get there via the scroll buttons.

Scott D10:54, 20 December 2011

Hi! To change the range of years you can add the following change in the datepicker.js file. Look for this piece of code:

inputShow.datepicker( {
                        'showOn': 'both',
                        'buttonImage': params.buttonImage,
                        'buttonImageOnly': false,
                        'changeMonth': true,
                        'changeYear': true,
                        'altFormat': 'yy/mm/dd',
                        // Today button does not work (http://dev.jqueryui.com/ticket/4045)
                        // do not show button panel for now
                        // TODO: show date picker button panel when bug is fixed
                        'showButtonPanel': false,
                        'firstDay': params.firstDay,
                        'showWeek': params.showWeek,
                        'dateFormat': params.dateFormat,
                        'beforeShowDay': function ( date ) {return SFI_DP_checkDate( '#' + input_id + '_show', date );}
                } );

Then add the following line inside that block:

'yearRange': 'c-200:c+10',

That will change the range of years (200 in the past from today's year and 10 years in the future). More info can be found in DatePicker documentation.

FrancoIacomella (talk)17:37, 28 May 2013


The Menuselect input type is depending on the Semantic TreeView extension. Are there plans to further support this input type or will it be phased out? I guess a note about this should be on this extension's page. Cheers

[[kgh]] (talk)19:09, 26 March 2013

Semantic TreeView is IMHO not maintainable. Instead I improved the tree format of Extension:SemanticResultFormats. Guess I should also update the menuselect documentation,

F.trott (talk)20:30, 26 March 2013

Yeah, that's why I asked. :) Cheers

[[kgh]] (talk)21:41, 26 March 2013

Would absolutely love to see some syntax using the new tree format!, 13 April 2013

I changed the example.

F.trott (talk)16:58, 13 April 2013

I have got an other question abou menuselect: is it possible to select a value the type comma and selcet a second value? Becau in my case the first value is always been overwritten! Thanks for help.

Zym (talk)13:31, 18 April 2013

Sorry, it is not possible to create a comma separated list with menuselect.

F.trott (talk)13:40, 18 April 2013

Thank you for the fast answer! What do you recommend instead? More multiselcet fields in a row mapping the same Property? Or maybe change the JavaScript of multiselect? If yes: where?

Zym (talk)13:48, 18 April 2013

You could try some other input type, e.g. the twolistboxes input type available in the development version of the extension. You could of course also have several inputs or use a multiple template form. If you want to patch menuselect, have a look at the libs/menuselect.js file.

F.trott (talk)07:26, 19 April 2013

If I put more multiselctfields in a row for the same property the last textfield overwrites the others. So I will try to change the libs/menuselect.js file.

Zym (talk)12:05, 22 April 2013

Disable selecting dates from future

Need an option to disable future dates selection in datepicker.

Vlsergey (talk)12:51, 20 December 2012

Have not tried, but if you set the "last date" parameter to todays date (e.g. {{CURRENTYEAR}}/{{CURRENTMONTH}}/{{CURRENTDAY}}) it should work.

F.trott (talk)20:52, 14 January 2013

Dates are stored like this YYYY/MM/DD. What is the best way to store this date as an ISO-formatted date (YYYY-MM-DD) in the template for this form?

    [[Has start date::{{{Start date|}}}]]

I tried #formatdate/#dateformat but didn't get it to work.

    [[Has start date::{{#formatdate:{{{Start date|}}}|ISO 8601}}]]

If it is not possible to store the date this way: Is it possible to display dates as YYYY-MM-DD?

Sorry, I don't know any solution.

Martinwiss (talk)23:45, 26 November 2012


    [[Has start date::{{#replace:{{{Start date|}}}|/|-}}]]
Martinwiss (talk)23:53, 26 November 2012

You could also use the #time function fropm the ParserFunctions extension:

[[Has start date::{{#time:Y-m-d|{{{Start date|}}}}}]]

see Help:Extension:ParserFunctions#.23time

F.trott (talk)07:33, 27 November 2012

datepicker with german user localisation doesn't work correctly

Hi all! First, a big big thank to all who lets live this great software! And sorry for my english. As a rather unexperimented admin of a unfortunately non-public smw-wiki I don't now where to tune for this problem: The datepicker popup let me choose a date, but it fills in the form-field in a strange way: "TT.November.JJ" instead of "31/10/2012". The saved page contain also the defective string. When I edit a page witch contains already a correct date-string with the datepicker oder the datetimepicker-form, it appears also wrong. But this occurs only if the Language in "my preferences" is set to German. So, English and French works well. See the screenshot on [1]. Contrary, the timpicker-form works well for all languages. This behaviour occurs only since the last upgrading of some extensions, but I don't now exactly of which one. Actually, this is our installation: [2]. Thanks for help!

Lugant (talk)23:08, 31 October 2012

Sorry for this typo: in the text above, "31/10/2012" should be "2012/10/31" since this is the only accepted format. The described problem still occurs.

Lugant (talk)23:48, 31 October 2012

Hi Lugant,

I think you caught a version with an error in the German translations. Sorry about that. To fix it please find the file SemanticFormsInputs.i18n.php. There around line 240 you should find the German translations of the dateformat. Please fix them so they look like this:

'semanticformsinputs-dateformatlong' => 'd. MM yy',
'semanticformsinputs-dateformatshort' => 'dd.mm.yy',

Alternatively you can use the current development version (https://gerrit.wikimedia.org/r/gitweb?p=mediawiki/extensions/SemanticFormsInputs.git;a=snapshot;h=refs/heads/master;sf=tgz) which should be stable.


F.trott (talk)07:50, 1 November 2012

Hi F.trott,

Thank you for your reply. The problem is solved by following exactly yours suggestion. I've changed the two erroneous lines in SemanticFormsInputs.i18n.php and everything works well. Thank you again.

have a nice day!

Lugant (talk)21:36, 1 November 2012
First page
First page
Previous page
Previous page
Last page
Last page