Wikimedia Developer Support

[MediaWiki-l] extension CategoryTree <span tag showing


#1

Hello,

This is a puzzle to me.

<span style="color:#0654AD;">▼</span>

shows the span tag, like above, when I open the category tree on my
test wiki running MediaWiki 1.31.1 with extension CategoryTree
(bundled in MediaWiki) enabled. That span tag should get parsed by the
browser, not be displayed.

This did not happen with new MW 1.31.1 install plus CategoryTree
(which is included in that version of MW). That expanded or closed the
category trees for me correctly.

It started happening when I dumped my wiki's database into that new MW
1.31.1 instance's database. Yes, I did run maintenance/update.php
after dumping my wiki's database in there. Didn't have any trouble
with that.

It is a puzzle to me whow the database input and update can cause this
problem of the span tag showing. The span tag is dynamic text -- it is
not selectable in the web browser. The rest of the page text is, but
that problem span tag and it's arrow is not, for example, when you
click on one of the ► arrows on my test wiki's Contents page, which
uses CategoryTree, here:
http://m.rogerchrisman.com/Contents you will see the problem <span tag.

I don't think my site root level URL shortening is the problem.
CategoryTree worked fine with that, till I dumped my teflpedia wiki's
database into above test wiki. That is when the <span tag started
showing.

The MediaWiki 1.22.2 wiki I am trying to upgrade
(http://teflpedia.org) uses an old version (from about 2013) of
CategoryTree that does not have this problem. I tested installing the
old version of CategoryTree on my upgraded wiki and that works fine.
However, I'd rather not use an out of date version, and I am puzzled
as to what is causing this <span style="color:#0645;"> tag to show up
displayed on the page instead of being interpreted as html the way it
normally is. It shows up in both Firefox and in Microsoft Edge on my
Windows 10 and in Firefox on my Xubuntu. Haven't tested other
browse►rs.

Welcome to test it in your browser:
http://m.rogerchrisman.com/Contents
(and click one of the little arrows, not the category page names, to
expand or close the tree). That is what shows the problem <span tag.

Puzzled!

Happy New Year!

Roger
I can't believe it, 2019... almost!


#2

Probably the icon-related messages you customized (MediaWiki:Categorytree-collapse-bullet, MediaWiki:Categorytree-empty-bullet, MediaWiki:Categorytree-expand-bullet used to be interpreted as HTML in earlier versions but are plain text now.


#3

FIXED IT!

While checking Special:AllMessages (specifically all modified
messages) I noticed I had <span color in the three pages that define
the arrows. Removed the <span tags on these three pages and the
problem vanished! :slight_smile:

MediaWiki:Categorytree-collapse-bullet
MediaWiki:Categorytree-expand-bullet
MediaWiki:Categorytree-empty-bullet

Back to upgrading my wiki from MW1.22.2 to MW1.31.1.

Roger :slight_smile: