mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Cite
synced 2024-11-28 00:40:12 +00:00
T58916: Parse extension parameters as plain text
Also encode cite ids properly as now they can contain arbitrary text. Change in blacklist due to this. TODO: Investigate if it would be better to do this directly in the tokenizer. Change-Id: Ic112124e90d256d73a351d0d57fe3c7546fa065f
This commit is contained in:
parent
9e6055d547
commit
3c82fb7787
|
@ -154,7 +154,8 @@ function makeValidIdAttr(val) {
|
|||
// Looks like Cite.php doesn't try to fix ids that already have
|
||||
// a "_" in them. Ex: name="a b" and name="a_b" are considered
|
||||
// identical. Not sure if this is a feature or a bug.
|
||||
return val.replace(/\s/g, '_');
|
||||
// It also encodes them and then substitutes '%' with '.'.
|
||||
return encodeURIComponent(val.replace(/\s/g, '_')).replace(/%/g, '.');
|
||||
}
|
||||
|
||||
RefGroup.prototype.add = function(references, refName, about, skipLinkback) {
|
||||
|
|
Loading…
Reference in a new issue