Page MenuHomePhabricator

Provide a mechanism for site admins to hide the "This is my own work" checkbox for third party wikis which don't care
Open, LowestPublic

Assigned To
Authored By
Jul 12 2016, 8:34 AM
Referenced Files
F34187400: HtT2of1qFV.gif
Mar 24 2021, 10:44 PM
"Like" token, awarded by freephile."Baby Tequila" token, awarded by Urfiner."Like" token, awarded by Framillien."Like" token, awarded by Bryandamon."Like" token, awarded by Rcdeboer."Heartbreak" token, awarded by Joris."Like" token, awarded by Cuibonobo."Like" token, awarded by rakekniven.


Planetenxin on says:

We use VisualEditor in corporate environments and users often complain about the "This is my own work" checkbox they have to tick before uploading. Is there a way to tick the checkbox by default or hide it at all?

I'd go as far as to ask an additional preference about this, but I know how James feels about it...

Event Timeline

Preferably, reuse or share a setting with the upload wizard perhaps ?

Even if there was such a setting, this code has no dependency on UploadWizard.

My point was, such an option should probably not be limited to one extension, as I think that this is something people want to configure just once.

"I'm an internal wiki, don't bother me with details like licenses etc"

Jdforrester-WMF renamed this task from Media upload: tick / hide "This is my own work" checkbox? to Provide a mechanism for site admins to hide the "This is my own work" checkbox for third party wikis which don't care.Jul 12 2016, 7:12 PM
Jdforrester-WMF triaged this task as Lowest priority.
Jdforrester-WMF edited projects, added Multimedia; removed VisualEditor.
Jdforrester-WMF updated the task description. (Show Details)
matmarex subscribed.

The dialog is not UploadWizard, but it's not specific to VisualEditor either, it's used by both editors. See

I think this is a special case of T121012: Cross-wiki-upload: Allow users to specify source and specific license , where the license would be "no license at all". This is indeed currently not configurable, the best you can do is edit the MediaWiki: namespace messages to say something else.

Restricted Application added a subscriber: Steinsplitter. · View Herald Transcript

... it's not about the message itself, it is really the extra click that is not wanted in "internal wikis". So having an option to "bypass" this question would be great.

Have the same issue here. Want to get rid of the checkbox and extra click.

As an admin of a private wiki who has spend MANY hours translating word docs to wiki articles, I would just like to say that this referenced check box is the actual devil himself in text form, stealing away tiny slices of my life by the hundreds each day. If I didn't have actual work to do I'd track the devil down myself in the code but it would be nice to fix it for others too. Why is this 'Lowest' priority? I see the devil's minions at work.

yes, would be great if this could become a higher priority

Hello @Jdforrester-WMF please see demand and rethink priority.

The word “demand” has a harsh meaning where I come from. Let’s instead make a strong argument for the feature request with more voices. If others reading this are also stymied, please speak up.

I also don’t think Mr. Forrester can make this happen on his own. I believe his current role is removed from product decisions for both VE and UploadWizard. But I would hope we could ask him to use his influence to help the cause. :)

How do you suggest we add voices? Subscribed, but phabriactor has no +1 function.
I'm using MW for functional documentation in an enterpise setting. I'd rate this bug "papercut". but a papercut for every single editor I have. (And very inaccurate for enterprise; documentation need not be 'own work'.)

Tgr subscribed.

Subscribed, but phabriactor has no +1 function.

People typically use the "Award token" option (and then add a heart or thumbs-up or something like that). Of course actually describing how (and how much) it affects you is more useful.

There's also the MediaWiki Stakeholders' Group for coordinating / prioritizing third-party requests.

rakekniven rescinded a token.
rakekniven awarded a token.

Agree with description, we are also using MediaWiki in corporate environments. Our users in this context doesn't understand this checkbox. So, if we had an option to remove/hide this option, it would be great.


This seems easy... Why hasn't anyone done this in the past three years?

On my corporate wiki it is a huge pain. If page containst 10-20 images, you have to do it again and again.. It frustrates to the point where some sub-teams switch to other products. Yes, it is not only about checkbox but about all the extra steps in general.

Usually all we need is to insert image as is and we don't care about it's naming much.

Below I provide 2 stupid patches to improve your life if you don't want to wait for an official fix.

patch1 - ignore 'own work' checkbox

Looks like if you want only to remove the 'own work' checkbox, you'll need to change core code.

I believe, necessity to check it should be passed via some parameter

From a01efa9559733979bd1e44af4d1da6530a0c712e Mon Sep 17 00:00:00 2001
From: Urfiner <>
Date: Wed, 24 Mar 2021 22:47:01 +0100
Subject: [PATCH] Skip own work check

 .../BookletLayout.js                                            | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/resources/src/mediawiki.ForeignStructuredUpload.BookletLayout/BookletLayout.js b/resources/src/mediawiki.ForeignStructuredUpload.BookletLayout/BookletLayout.js
index 4515aaa7..b1f1529f 100644
--- a/resources/src/mediawiki.ForeignStructuredUpload.BookletLayout/BookletLayout.js
+++ b/resources/src/mediawiki.ForeignStructuredUpload.BookletLayout/BookletLayout.js
@@ -221,7 +221,7 @@
 	mw.ForeignStructuredUpload.BookletLayout.prototype.onUploadFormChange = function () {
 		var file = this.selectFileWidget.getValue(),
 			ownWork = this.ownWorkCheckbox.isSelected(),
-			valid = !!file && ownWork;
+			valid = !!file; // && ownWork;
 		this.emit( 'uploadValid', valid );

patch2 - drag'n'drop as is

There is also another way if you only care about VisualEditor. Instead of removing license requirement you can just skips as much steps as possible in a stupid way.
Code is not suitable for commiting . It is just a general idea how that can be handled on private wikis which don't care about correct image metadata.

If some operation fails, dialog will stuck on the problematic step

Here I have imlpementation for drag and drop only. Additionally I change defaults for inserted images

If you need the same for other ways of image upload, it should be simple. I just hope that will save time for some other private wiki owners

From 7557692c96b63f3f30d985fe97de2855281305f6 Mon Sep 17 00:00:00 2001
From: Urfiner <>
Date: Wed, 24 Mar 2021 21:59:57 +0100
Subject: [PATCH] Fix VE for autoupload

 .../ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js   | 23 ++++++++++++++-----
 1 file changed, 17 insertions(+), 6 deletions(-)

diff --git a/modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js b/modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
index 2b50b387c..b2c403756 100644
--- amodules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
+++ bmodules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
@@ -297,7 +297,7 @@ ve.ui.MWMediaDialog.prototype.initialize = function () {
 			data: 'none',
 			icon: 'imageLayoutBasic',
 			label: ve.msg( 'visualeditor-dialog-media-type-none' )
-		} )
+		} ),
 	] );
 	typeSelectField = new OO.ui.FieldLayout( this.typeSelectDropdown, {
 		align: 'top'
@@ -873,11 +873,11 @@ ve.ui.MWMediaDialog.prototype.confirmSelectedImage = function () {
 					href: './' + title,
 					src: info.url,
 					resource: './' + title,
-					width: info.thumbwidth,
-					height: info.thumbheight,
+					width: info.width,
+					height: info.theight,
 					mediaType: info.mediatype,
-					type: 'thumb',
-					align: 'default',
+					type: 'none',
+					align: 'none',
 					defaultSize: true
@@ -1154,11 +1154,22 @@ ve.ui.MWMediaDialog.prototype.getSetupProcess = function ( data ) {
 				this.mediaUploadBooklet.initialize() :
 			).then( function () {
-				dialog.actions.setAbilities( { upload: false, save: false, insert: false, done: false } );
+				dialog.actions.setAbilities( { upload: false, save: false, insert: false, done: false } );
 				if ( data.file ) {
 					dialog.searchTabs.setTabPanel( 'upload' );
 					dialog.mediaUploadBooklet.setFile( data.file );
+					$.when( dialog.getActionProcess( 'upload' ).execute() ).done(function (result) {
+						$.when( dialog.getActionProcess( 'save' ).execute() ).done(function (result) {
+							dialog.confirmSelectedImage();
+					        	$.when( dialog.getActionProcess( 'choose' ).execute() ).done(function (result) {
+								$.when( dialog.getActionProcess( 'insert' ).execute() ).done(function (result) {
+									// Everything is done
+								});
+							});
+						});
+					});
 			} );
 		}, this );

The last one looks like:

HtT2of1qFV.gif (788×1 px, 496 KB)

Another fix for this, building on from the instructions provided by @Urfiner:

Edit: /resources/src/mediawiki.ForeignStructuredUpload.BookletLayout/BookletLayout.js

Find the block /* Setters */ (should be at the bottom)

/* Setters */

 * @inheritdoc
mw.ForeignStructuredUpload.BookletLayout.prototype.clear = function () { this );

        this.ownWorkCheckbox.setSelected( false );
        this.categoriesWidget.setValue( [] );
        this.dateWidget.setValue( '' ).setValidityFlag( true );

Adjust this.ownWorkCheckbox.setSelected( false ); to this.ownWorkCheckbox.setSelected( true );

Now the checkbox will be checked by default.

Hi all, apologies in advance for this horrid, no-good, evil, dirty hack, but here's a patch which will remove the page element(s) in question. I have given this only cursory testing, and it appears to work fine, but it's entirely possible that in my naïveté, I've missed something terribly obvious, or obviously terrible. Yes, I feel the same compunction about "hacking core" that everyone else does, but… here we are.

--- fresh-1.35/resources/src/mediawiki.ForeignStructuredUpload.BookletLayout/BookletLayout.js   2023-09-28 21:52:49.621705300 -0400
+++ w/resources/src/mediawiki.ForeignStructuredUpload.BookletLayout/BookletLayout.js    2024-02-16 23:22:24.075126148 -0500
@@ -180,12 +180,12 @@
                        new OO.ui.FieldLayout( this.selectFileWidget, {
                                align: 'top'
                        } ),
-                       new OO.ui.FieldLayout( this.ownWorkCheckbox, {
+                       /*new OO.ui.FieldLayout( this.ownWorkCheckbox, {
                                align: 'inline',
                                label: mw.msg( 'upload-form-label-own-work' ),
                                help: this.$ownWorkMessage,
                                helpInline: true
-                       } ),
+                       } ),*/
                        new OO.ui.FieldLayout( this.messageLabel, {
                                align: 'top'
                        } )
@@ -221,7 +221,8 @@
        mw.ForeignStructuredUpload.BookletLayout.prototype.onUploadFormChange = function () {
                var file = this.selectFileWidget.getValue(),
                        ownWork = this.ownWorkCheckbox.isSelected(),
-                       valid = !!file && ownWork;
+                       // hat tip:
+                       valid = !!file; //&& ownWork;
                this.emit( 'uploadValid', valid );

There are still two steps required for every upload, the second for filling in the destination filename and description. I'm personally OK with that. Your mileage may vary with newer (supported) releases. Yes, yes, I know. PHP 7.4 has been a problem at my site for… reasons.

I don't know how this affects VisualEditor, or drag-and-drop uploads because I haven't been able to get VE running properly in my environment—yet. I frankly didn't even know that drag-and-drop uploads were a thing in VE, but that sounds nice. *sigh*

Asking my users to curse and swear that something they're uploading is "their own work," means half the time asking them to lie. I get why this is necessary for Wikipedia and so on, so this is not a gripe at all, just stating the ethical conundrum. It feels bad to lie, even to some JavaScript and PHP code with no feelings. ;)

There is the extension EnhancedUpload that gets rid of this and also other options of VE.