Last modified: 2013-06-24 19:28:40 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T16176, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 14176 - Add ability to disable MediaWiki messages
Add ability to disable MediaWiki messages
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Interface (Other open bugs)
unspecified
All All
: Lowest enhancement with 2 votes (vote)
: ---
Assigned To: Nobody - You can work on this!
: easy, i18n
Depends on:
Blocks: 18521 35151
  Show dependency treegraph
 
Reported: 2008-05-19 02:32 UTC by MZMcBride
Modified: 2013-06-24 19:28 UTC (History)
11 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description MZMcBride 2008-05-19 02:32:16 UTC
It would be nice to have a way to disable certain system messages. Currently, if you blank them, they revert to the default, so various hacks are used instead. People insert &nbsp; or <p></p>, but having a consistent way to disable messages would be best. Perhaps use a - like the sitenotice does?
Comment 1 Danny B. 2008-05-19 03:32:39 UTC
I'm not sure about "-" since some messages may contain only that char (I saw wiki with that as category separator), however I support this with all ten fingers.
Comment 2 Roan Kattouw 2008-05-19 13:32:53 UTC
Why do empty messages render the default anyway? If you want the default message, it seems to me that the most intuitive thing to do is to just delete the message page.
Comment 3 Tim Starling 2008-10-06 07:19:38 UTC
(In reply to comment #2)
> Why do empty messages render the default anyway? 

I don't know, I fixed this once already. It must be a regression.
Comment 4 P.Copp 2012-03-11 08:08:16 UTC
In MessageCache.php:
708	                        if ( substr( $entry, 0, 1 ) === ' ' ) {
709	                                return substr( $entry, 1 );

> var_dump( substr( ' ', 1 ) );
bool(false)

Changing it to mb_substr would work, as mb_substr doesn't have this odd behavior of returning false. Can we fix this or do some wikis rely on the current behavior?
Comment 5 Nemo 2013-01-11 18:49:22 UTC
-easy: I doubt it is, involving message cache etc.
Comment 6 MZMcBride 2013-01-12 05:14:39 UTC
(In reply to comment #5)
> -easy: I doubt it is, involving message cache etc.

This isn't evidence of the bug not being easy. Restoring the keyword. Also, read comment 4.
Comment 7 p858snake 2013-05-17 10:24:48 UTC
(In reply to comment #3)
> (In reply to comment #2)
> > Why do empty messages render the default anyway? 
> 
> I don't know, I fixed this once already. It must be a regression.

Did anyone get a chance to look at why this was reverted/when it regressed?
Comment 8 Gerrit Notification Bot 2013-05-17 12:12:43 UTC
Related URL: https://gerrit.wikimedia.org/r/64277 (Gerrit Change Id91914a3701fe53f1e2e894824512489392c628b)
Comment 9 MZMcBride 2013-05-21 03:57:42 UTC
(In reply to comment #8)
> Related URL: https://gerrit.wikimedia.org/r/64277 (Gerrit Change
> Id91914a3701fe53f1e2e894824512489392c628b)

MZMcBride wrote:

---
I'm concerned that this is a "scap trap" for Wikimedia wikis and possibly needs more emphasis/prominence in the release notes.

As I understand it (and please correct me if I'm mistaken), the old behavior was that when a MediaWiki message existed (as a page in the page table) but was blank, it reverted to the default message. After this proposed changeset, the new behavior will be that when a MediaWiki message exists and is blank, it will be output as blank.

Generally, it's good to correct this behavior. But I'm concerned that editors have relied upon the old behavior and will be surprised when it suddenly changes.
---

Parent5446 wrote:

---
@MZMcBride - Actually, the previous behavior was slightly different. What would happen is that on the first request, a blank message would be shown as blank. But then on subsequent requests (after the message was cached), it would return false and fall back to the default.

Nonetheless you have a point. Most likely some people might be relying on this change. Maybe I should add it to the breaking changes section in the release notes?
---

I'm not sure.
Comment 10 MZMcBride 2013-05-21 04:00:59 UTC
(In reply to comment #9)
> I'm concerned that this is a "scap trap" for Wikimedia wikis [...]

Greg G.: copying you due to this.
Comment 11 Nemo 2013-05-21 05:49:50 UTC
The jargon for "disable this message" is "-", not "", isn't it? (But it works only on some messages.) Is there any reason why blank is better than hyphen to add ability to disable MediaWiki messages?
Comment 12 MZMcBride 2013-05-21 14:48:12 UTC
(In reply to comment #11)
> The jargon for "disable this message" is "-", not "", isn't it? (But it works
> only on some messages.) Is there any reason why blank is better than hyphen
> to add ability to disable MediaWiki messages?

Comment 1 discusses this. :-)
Comment 13 Tim Starling 2013-06-11 22:34:58 UTC
For the record, the original change to allow messages to be blank without falling back to the default was r10975 (September 2005).
Comment 14 Tyler Romeo 2013-06-11 23:04:38 UTC
Has this been fixed? The above patch has been merged.
Comment 15 MZMcBride 2013-06-19 13:05:15 UTC
Bug 48956 notwithstanding, this bug is currently fixed (as bug 49793 demonstrates). Updating the bug status accordingly.
Comment 16 Nemo 2013-06-20 09:44:04 UTC
(In reply to comment #15)
> Bug 48956 notwithstanding, this bug is currently fixed (as bug 49793
> demonstrates). Updating the bug status accordingly.

So how does one disable the local message i.e. restore default? Only by deleting?
Comment 17 MZMcBride 2013-06-21 01:35:50 UTC
(In reply to comment #16)
> (In reply to comment #15)
>> Bug 48956 notwithstanding, this bug is currently fixed (as bug 49793
>> demonstrates). Updating the bug status accordingly.
> 
> So how does one disable the local message i.e. restore default? Only by
> deleting?

You disable the message by blanking the page. You revert to the default by deleting the page. I think this is logical behavior.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links