Last modified: 2014-11-17 10:36:26 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 T6469, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 4469 - Provide per-namespace site notices
Provide per-namespace site notices
Status: REOPENED
Product: MediaWiki
Classification: Unclassified
Interface (Other open bugs)
unspecified
All All
: Low enhancement with 8 votes (vote)
: ---
Assigned To: Nobody - You can work on this!
:
: 6391 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-01-03 17:05 UTC by Sy Ali
Modified: 2014-11-17 10:36 UTC (History)
10 users (show)

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


Attachments

Description Sy Ali 2006-01-03 17:05:55 UTC
MediaWiki:<namespace>:Sitenotice
e.g. MediaWiki:Help:Sitenotice

Implement per-namespace sitenotice functionality.  For example, a sitenotice on
"Help:" would allow for a specific notification for readers of the documentation
which may not apply to the entire site.

This is much easier than inserting a template to every page in a potentially
large namespace.
Comment 1 Rob Church 2006-01-04 11:10:24 UTC
Would be more inclined to use MediaWiki:Sitenotice/<namespace> syntax, falling
back to MediaWiki:Sitenotice if it doesn't exist.
Comment 2 Sy Ali 2006-01-04 14:05:50 UTC
That makes sense.
Comment 3 Ævar Arnfjörð Bjarmason 2006-01-05 17:03:58 UTC
(In reply to comment #1)
> Would be more inclined to use MediaWiki:Sitenotice/<namespace> syntax, falling
> back to MediaWiki:Sitenotice if it doesn't exist.

That would potentially conflict with the message/language syntax
Comment 4 Rob Church 2006-01-05 21:06:00 UTC
(In reply to comment #3)
> That would potentially conflict with the message/language syntax

Then let's use a new message altogether - "MediaWiki:Namespacebanner/<NS>".

Comment 5 lɛʁi לערי ריינהארט 2006-01-06 10:29:08 UTC
Hallo!

The "/" character is used already for user interface language variants. Would it
be more appropriate to use the "-" character?

"MediaWiki:Namespacebanner-<NS>"

questions:
a) In page titles namespaces are *not* casesensitive, see
[[en:mEDIawIKi:Sitenotice]]. However they will / can be in a syntax as
"MediaWiki:Namespacebanner-<NS>".
b) Should <NS> be
b1) a value (negative or positive)
b2) a "generic" namespace? "Category" or "category"?
b3) a localized namespace? Including all backward compatibility hacks?
c) Would there be a support for custom namespaces also?

best regards reinhardt [[user:gangleri]]

P.S. I emulated such a "per namespace help" using templates at "WikiPage". The
work was lost.
Comment 6 Magnus Manske 2006-01-08 19:54:25 UTC
Fixed in CVS:
MediaWiki:Namespacebanner contains the "base name", to which the name of the
namespace is appended, like "basename-namespace". By default the base name is
also "Namespacebanner" to add confusion. In namespace names, spaces are replaced
by "-" (due to some weird message handling bug).
So the namespace-specific notice messages loke like:
"Namespacebanner-" (main namespace)
"Namespacebanner-Talk" (Talk namespace)
"Namespacebanner-MediaWiki-talk" (for MediaWiki_talk)
Comment 7 Borgx 2006-02-01 02:52:58 UTC
The feature has not been activated until now. Why?
Comment 8 Rob Church 2006-02-01 02:55:23 UTC
As far as I am aware, it's not present in the code at this time. I believe the
first implementation was considered to be an absolute mess, and the second was
discovered to cause some bizarre items within the cache.

There isn't a clean implementation for this at the present time.
Comment 9 Borgx 2006-02-01 02:58:16 UTC
(In reply to comment #8)
> As far as I am aware, it's not present in the code at this time. I believe the
> first implementation was considered to be an absolute mess, and the second was
> discovered to cause some bizarre items within the cache.
> 
> There isn't a clean implementation for this at the present time.
Bug reopened.
Comment 10 bdk 2006-02-01 03:37:36 UTC
Just a note on importance:
We *really* need such a feature for mediawiki.org, where specific namespace(s) 
- different from the rest of contents on this wiki - generally should be in the 
public domain; primarily for a free (and easy to copy) manual/handbook, that is 
intended to be shipped with the package/distribution in the future, at least as a 
download option (perhaps a specific dump). 
Comment 11 Rob Church 2006-02-01 07:27:34 UTC
Couple of points:

[a] We need a cleaner naming scheme for the messages
[b] This should be able to be switched off in the configuration, for performance
Comment 12 lɛʁi לערי ריינהארט 2006-02-01 13:00:34 UTC
(In reply to comment #6)
> "Namespacebanner-" (main namespace)
> "Namespacebanner-Talk" (Talk namespace)
> "Namespacebanner-MediaWiki-talk" (for MediaWiki_talk)

(In reply to comment #11)
> [b] This should be able to be switched off in the configuration, for performance

There is also another point: Custom namspaces do not have "generic names".
What about using "Namespacebanner-<namespace_value>"?

"Namespacebanner-0" (for '' main namespace)
"Namespacebanner-1" (for 'Talk' namespace)
"Namespacebanner-9" (for 'MediaWiki_talk' namespace)
also
"Namespacebanner--1" (for 'Special' namespace)
"Namespacebanner-101" (for custom namespace 'Portal_talk') at
[[en:template:wikivar#ns_101]].
Comment 13 lɛʁi לערי ריינהארט 2006-02-01 13:01:32 UTC
Sorry! Please read above:
(In reply to comment #11)
> [a] We need a cleaner naming scheme for the messages

Comment 14 Melancholie 2006-02-07 22:23:56 UTC
Isn't the method used at [[de:MediaWiki:Noarticletext]] 
working for [[MediaWiki:Sitenotice]], too?
Comment 15 lɛʁi לערי ריינהארט 2006-02-08 20:37:28 UTC
(In reply to comment #14)
> Isn't the method used at [[de:MediaWiki:Noarticletext]] 
> working for [[MediaWiki:Sitenotice]], too?

You will find both *language* and *project* dependent pages at
http://de.wikipedia.org/w/index.php?title=special:Prefixindex/MediaWiki_Noarticletext_NS&namespace=10
These are located in the *template* namespace not in the MediaWiki namespace.

It creates different variants of 'MediaWiki:Noarticletext'.
Comment 16 Melancholie 2006-03-12 19:41:05 UTC
OK, have a look on [[b:als:MediaWiki:Anonnotice]] to see how my suggestion works
(it's the same for "MediaWiki:Sitenotice", of course)!

See [[b:als:MediaWiki Diskussion:Anonnotice]] for an overview of the namespace
messages, to see what has to be done before every namespace have its *own* (or
shared) message. Have a close look on the given comments and on the structure of
the sub pages.

Because it is possible to devide MediaWiki:Sitenotice into different sub
notices, I close this bug now.
Comment 17 Borgx 2006-03-13 01:14:42 UTC
(In reply to comment #16)
> OK, have a look on [[b:als:MediaWiki:Anonnotice]] to see how my suggestion works
> (it's the same for "MediaWiki:Sitenotice", of course)!
> 
> See [[b:als:MediaWiki Diskussion:Anonnotice]] for an overview of the namespace
> messages, to see what has to be done before every namespace have its *own* (or
> shared) message. Have a close look on the given comments and on the structure of
> the sub pages.
> 
> Because it is possible to devide MediaWiki:Sitenotice into different sub
> notices, I close this bug now.

Not working for me. (see
http://id.wikipedia.org/wiki/Mediawiki:Anonnotice/Mediawiki)
I put message in MediaWiki:Anonnotice/MediaWiki , the default anonnotice for
MediaWiki still MediaWiki:Anonnotice
Comment 18 Melancholie 2006-03-13 02:23:42 UTC
Yes, of course you have to change [[id:MediaWiki:Anonnotice]] 
before; see [[b:als:MediaWiki:Anonnotice]]. --- Best regards, 
Melancholie
Comment 19 Melancholie 2006-03-13 02:29:32 UTC
Oh, and go over [[b:als:MediaWiki_Diskussion:Anonnotice]] again to 
avoid red links, etc.
Comment 20 Borgx 2006-03-13 02:32:46 UTC
> Oh, and go over [[b:als:MediaWiki_Diskussion:Anonnotice]] again to 
> avoid red links, etc.

(In reply to comment #19)
Ah.. I understand.. You use tricky {{NAMESPACE}}. It's a workaround for this
bug. Nice. Thanks
Comment 21 Melancholie 2006-03-13 15:12:38 UTC
BTW: If you should think this feature should be implemented to the software,
consider reopening this bug. The advantages of a software solution would be:

1. Messages could fall back (not every single sub page has to be appointed every
time); see comment #1
2. By finding those MediaWiki messages in [[Special:Allmessages]] it isn't that
"intricate"
3. Something else?
Comment 22 Borgx 2006-08-30 02:12:45 UTC
Using ParserFunctions:

{{#ifexist:MediaWiki:Sitenotice/{{NAMESPACE}}|{{MediaWiki:Sitenotice/{{NAMESPACE}}}}}}
Comment 23 Rob Church 2006-08-30 04:44:37 UTC
This wasn't implemented in code, and wasn't WONTFIXED. Going to reopen.
Comment 24 Jamie Hari 2006-10-23 21:01:48 UTC
Any updates on this gem?
Comment 25 Melancholie 2006-10-25 17:23:37 UTC
Another parser function as workaround:

{{#ifeq:{{NAMESPACE}}|User talk|then text|else text}}

(BTW: {{#ifeq:{{NAMESPACEE}}|User_talk|then text|else text}})
(BTW: {{#ifeq:{{FULLPAGENAME}}|Special:Recentchanges|then text|else text}})
Comment 26 Melancholie 2006-10-25 17:25:05 UTC
Usage with no "else text":

{{#ifeq:{{NAMESPACE}}|User talk|then text|}}
Comment 27 Rob Church 2007-01-08 13:54:30 UTC
The site notices are cached once for all views; parser functions which depend
upon {{PAGENAME}} and {{NAMESPACE}} and so on won't work properly in these.
Comment 28 Rob Church 2007-03-29 21:24:02 UTC
*** Bug 6391 has been marked as a duplicate of this bug. ***
Comment 29 Roan Kattouw 2007-07-03 09:48:19 UTC
(In reply to comment #5)
> questions:
> a) In page titles namespaces are *not* casesensitive, see
> [[en:mEDIawIKi:Sitenotice]]. However they will / can be in a syntax as
> "MediaWiki:Namespacebanner-<NS>".
They won't. The MediaWiki code internally resolves 'mEDIawIKi' to 'MediaWiki'.
Comment 30 Thomas Bleher 2007-12-19 10:46:04 UTC
Doesn't the PageNotice extension (http://www.mediawiki.org/wiki/Extension:PageNotice) already provide all the needed functionality?
Comment 31 Sy Ali 2007-12-20 00:57:55 UTC
I think it does!
Comment 32 Thomas Bleher 2008-02-11 11:07:25 UTC
As the PageNotice extension (http://www.mediawiki.org/wiki/Extension:PageNotice) apparently has all the needed functionality, I'm closing this bug now. Wikis that want this functionality should open a separate bug to request installation of this extension.
Comment 33 Melancholie 2008-10-06 23:23:16 UTC
Not sure, but r41655 should be pretty the same when live!
Comment 34 MZMcBride 2008-10-06 23:25:10 UTC
Echoing comment 33; resolving as fixed.
Comment 35 Melancholie 2008-10-13 23:52:34 UTC
... has been reverted with r41994 (cache issues)
Comment 36 MZMcBride 2014-01-05 05:00:05 UTC
(In reply to comment #35)
> ... has been reverted with r41994 (cache issues)

Copying comment from r41655 here:

---
Causes a text load on parser cache hit. Reduces parser cache hit performance especially for ES clusters. Please implement this like every other double-underscore magic word and cooperate with the parser cache. Reverting.
---

"ES" refers to [[mw:Manual:External Storage]].
Comment 37 This, that and the other (TTO) 2014-01-05 05:20:09 UTC
Gerrit change #105434 attempts to re-introduce this feature.

The previous implementations have never lasted long without being reverted, so to respond to previous reasons for reversion:

* Personally I don't think the magic word is necessary, so this change does not implement it.
* Since this feature already exists in a way (Article::showNamespaceHeader can output a header on talk pages), I can't see how this additional functionality would make the caching situation any worse, although there may well be room for improvement.

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


Navigation
Links