Hi,
{F4312689}
It looks like == [[:{{BASEPAGENAME}}]] == section name do strange localisation of the mention in notifications.
Meet on https://fr.wikipedia.org/w/index.php?title=Discussion:OL_TV/Droit_d'auteur
Thanks you
Description
Details
Project | Branch | Lines +/- | Subject | |
---|---|---|---|---|
mediawiki/extensions/Echo | master | +23 -6 | Provide title when parsing wikitext |
Related Objects
- Mentioned In
- T143243: templates are not parsed in Flow topic headings
- Mentioned Here
- T120324: XSS in Flow topic titles
T128062: Keep notification excerpts compact and meaningful
T129439: topic-title-plaintext content format to treat topic-title-wikitext as plain text
rMWb79a28c4ce13: Merge "ApiParse: Deprecate prop=headitems"
Event Timeline
Confirmed in betalabs 1.28.0-alpha (b79a28c). The sample title when used as a section title on wikitext pages produces a dummy title.
Below is the screenshot when the sample title == [[:{{BASEPAGENAME}}]] == was used as a section title and as a topic title on wikitext page and Flow page topic. Flow topics handle it correctly.
Related to T129439: topic-title-plaintext content format to treat topic-title-wikitext as plain text.
Added the title sample to test cases for XSS test cases. Also see, T120324: XSS in Flow topic titles and T128062: Keep notification excerpts compact and meaningful for tested cases on Flow pages.
As @Mattflaschen-WMF says, this may just be a matter of ->plaintextParams(). If that's the case, let's just do this, but if it's a deeper problem around section support, let's put it off. There are other bugs around notifications and section handling and they're mostly due to sections not being very well supported in MediaWiki generally.
It's not about plaintextParams.
This is what DiscussionParser does:
echo MessageCache::singleton()->parse( '[[:{{BASEPAGENAME}}]]' )->getText(); <p><a href="/w/index.php?title=Badtitle/title_not_set_in_MessageCache::parse&action=edit&redlink=1" class="new" title="Badtitle/title not set in MessageCache::parse (page does not exist)">Badtitle/title not set in MessageCache::parse</a> </p>
Oh, ugh, I see, that's terrible. We'd have to parse it using the correct title somehow.
Change 308115 had a related patch set uploaded (by Sbisson):
Provide title when parsing wikitext
Checked the fix for Flow topic titles and wikitext section titles
Flow topics with == [[:{{BASEPAGENAME}}]] == will display it un-parsed, when wikitext pages will display it as as the page name link in a section title according to https://www.mediawiki.org/wiki/Help:Magic_words#Page_names
@SBisson should it be the same for Flow topics?