Extension talk:InputBox

About this board

For the page history, see also here. / previous talk on this page


%5B0%5D inserted into URL in stead of %5B%5D

2
Evolution and evolvability (talkcontribs)

There seems to be an issue with the preloadparams[] = parameter, where instead of including %5B%5D the text %5B0%5D is included, where the extra "0" prevevnts it from functioning.

see example: wikiversity.org/wiki/WikiJournal_Preprints

Any ideas for fixing this?

Ciencia Al Poder (talkcontribs)

comment and page don't work together

3
Adamw (talkcontribs)

The documentation suggests that the type=comment mode can be used to add a section to an existing page, when the page= parameter is provided:

<inputbox> type=comment page=Project:Sandbox </inputbox>

This would be great but it seems to not be how the feature works. Instead, the page parameter is ignored and the input text is used as the title of a new page. Not terribly useful when adding a section. I'd like to tweak this behavior to align with the documentation.

Adamw (talkcontribs)

I've searched for this syntax on all wikis using the search insource:inputbox insource:/type=comment/ -insource:/type=commenttitle/ insource:/inputbox.*page=.*\/inputbox/ and it seems that the few existing usages are a mistake. However, I don't think that I shouldn't simply change the behavior, because a few usages combine default= and hidden=yes to add a blank section to an existing page. It would be confusing if the input field was used as the page title only when page= is not present.

Arjunaraoc (talkcontribs)
Reply to "comment and page don't work together"

Button color/class and new section heading

4
Dvorapa (talkcontribs)

I'd like to propose two new functions to this extension. The first is a button color/class option. E.g. green button could be managed by "buttoncolor=green" or by 'buttonclass=mw-ui-progressive". The second is the level of the new section heading. E.g. 3rd heading could be managed by "headinglevel=3" What do you think? Could they be added?

Quiddity (WMF) (talkcontribs)

@Dvorapa: Re: button colors - One goal of the ongoing design work, is to make a User Interface that is consistent, as in, once people are familiar with a button's action/outcome, they can expect consistent results. Hence, the button to submit a form (as in this extension, and others) should always be a single color (blue in our case). There's some related information at this (slightly outdated) page: Wikimedia Foundation Design/Color usage#Functional Colors.

Re: heading levels - I almost filed a feature-request for this in phabricator, but then I couldn't find any examples (I checked a few dozen pages linked from en:WP:Requests). Here's what I had drafted; please add your use-case, and any pre-existing examples you can find, and post it in phab.

Title: Allow inputbox to create an H3 heading
Description: Suggested feature: The addition of a new parameter, which would let an inputbox specify what Heading level to use, when creating the `section=new`. This would allow editors to use it more flexibly, on pages where the desired practice is to create feedback in a series of H3 sections. Example pages where this practice is wanted (or already done but manually) include ...

Note: I'm not sure if this is technically feasible though. The current system just hooks into the standard "New topic" tab on all talkpages. Adding new code to allow changing the H-level might be more complex than is desired.

KHarold (WMF) (talkcontribs)

This would be super helpful - it is difficult to design a page around the light grey color of the 'create' button.

Quiddity (WMF) (talkcontribs)

@KHarold (WMF) I've commented at Phab:T88038 on the accessibility issues with the current light grey. See my answer to Dvorapa above, re: customizing colors. Hope that helps. :-)

Reply to "Button color/class and new section heading"

How can I allow a user to search by pageid?

2
Stevenpcox (talkcontribs)

I would like users to be able to look up an article based on pageid.

Using ?curid=PAGEID I can add the pageid to a url and go directly to the page. I would like to have a search function where the user input the pageid into a field, mediawiki appends the URL and the desired page opens up.

This should be easy. The only thing I cannot figure out is how to have the user type the pageid into a field and hit enter. From there I can turn it into a variable and inject it into the URL.

Krabina (talkcontribs)

I was looking for the same thing. Guess you have to use the Extension:PageForms for this (Query form).

Reply to "How can I allow a user to search by pageid?"

Could you implement an url=?

1
So9q (talkcontribs)
Reply to "Could you implement an url=?"

Option to choose between the VisualEditor and source editor

2
NemesisAT (talkcontribs)

For wikis with the VisualEditor installed, I think it would be handy to have a setting that enables a selector that allows a user to choose between creating an article in the VisualEditor and the source editor. It would certainly be neater than having two separate boxes.

78.107.233.101 (talkcontribs)

+1

Reply to "Option to choose between the VisualEditor and source editor"

Customise Button and Text Field colour, drop-shadow, border, etc?

3
62.96.213.62 (talkcontribs)

Hi, is it possible to modify the button colours, borders etc? And maybe the search box also?

Domtron vox (talkcontribs)

Haven't tried this for the input box, but you can make custom changes to the mediawiki CSS via the MediaWiki:Common.css page. Giving it a quick look the CSS classes your interested in is "mw-ui-button", "mw-ui-input", "mw-ui-input-inline", and possibly "mw-inputbox-centered" for the whole form area. (I just pulled these from the browser via the JS dev tools)


A bit late, but maybe it is useful to you or someone else.

Matjung (talkcontribs)

I tried this. Changing MediaWiki:Common.css worked for me.

.mw-inputbox-centered {text-align:left} /* not centered any more */

Reply to "Customise Button and Text Field colour, drop-shadow, border, etc?"
Solstag (talkcontribs)

Ni! Especially for new page creation, it would be very useful if there was a parameter to launch the editor/action in a new tab or window. Quite often a page will have a button to create or edit another page, while the documentation pertaining to the activity to be developed on the next page is to be found in the original page where the inputbox is. There's a (very low) limit to what we can do to help users with only preloaded comments. I deal with this problem very frequently in my Wikiversity courses, but also in the organization of wikiprojects and editathons/workshops. This seems like a low hanging (and tasty) fruit. Abraços!

Quiddity (WMF) (talkcontribs)

That sounds like a good idea to me! I've quickly searched Phabricator and I don't see an existing request for this feature idea. Please do file a new task there. (Ideally, include a specific example or two). Thanks!

Solstag (talkcontribs)
Reply to "New target (tab/window)"

useve and preload doesn't work together

2
Mattho69 (talkcontribs)

Hi,

I tried to converte some of our inputbox on fr.wikinews for using VE but it seems that useve is not working with preload parameter. (example here)


I look below and it seems to be the same issue that with prefix.


Ciencia Al Poder (talkcontribs)
Reply to "useve and preload doesn't work together"

Passing pagename as a category

2
Ziggurat146 (talkcontribs)

Firstly, sorry for the troubles as I'm new to mediawiki and can't find any beginner-friendly documentation that doesn't assume I can code in HTML/PHP, but hopefully this is an easy one.

I'm trying to use an InputBox to create a child page of the current page the InputBox is on, and for the life of me I cannot find a way to take the current PAGENAME and pass it to the created page to be it's Category. Can this be easily done, or am I destined to use a million and one templates for each of the possible categories? A crazy theory I had was to create a single page to be preloaded with the text 'Category:PAGENAME' (notated appropriately, of course), though I concluded it would likely grab the PAGENAME from the newly created page, which does me no good.

Thanks alot, I appreciate any help or guidance!

Ciencia Al Poder (talkcontribs)

In the preload page, you should put the category without variables nor PAGENAME. The category as-is.

This of course means you'll need to create one preload page for each page you put the inputbox in.

Reply to "Passing pagename as a category"
Return to "InputBox" page.