Viewing a history listing
Hi, can someone change MediaWiki:Wmobile-copyright/en to use quotation marks rather than apostrophes in the links as they're currently broken
Single quotation marks are valid in the HTML syntax for attributes.
Remember that this resource is NOT written using the Mediawiki syntax, but the plain HTML syntax, so even if it does not render correctly on this wiki, this is only because this wiki attempts to parse it as Mediawiki (where even the
<a href="URL">text</a> is not permitted by the wiki; so if it was written using the MediaWiki syntax and rendered by MediaWiki, it would be .
[URL text] instead; this is not the case here).
So changing the ASCII single quote to ASCII double quotes would not change the way this message is rendered here on this wiki. Keep it in plain HTML: the message is intended to be rendered only locally by the Mobile app (which uses its own internal HTML renderer with its own embedded browser component, and does not parse the Mediawiki syntax, this text is emitted as is) and NOT on a MediaWiki server...
Nothing is broken here!
Note: you are still free to change these quotes in translations, as long as you use a valid HTML syntax (so don't change the ASCII
> delimiting the HTML opening and closing tags.
As well only use a plain URL (which you may need to change if it has to link to another translated page on the same target site, and keep the "https://" protocol unchanged).
And you are free to use the the quotation marks and apostrophes and all other punctuation appropriate in the target language for the text part of the link. You can test your translation by copy-pasting it in a plan-text file saved in ".html" format, and open it in your browser (unfortunately, the source message is not "meta-tagged" as using the HTML syntax; that's something that Translate wiki should propose to indicate its expected syntax, but that would also involve importing the source message with metadata in the package).
Oh, I thought it was broken because the links broke when I clicked on them (it went to http://en.wikipedia.org/wiki/Wikipedia:Text_of_Creative_Commons_Attribution-ShareAlike_3.0_Unported_License')
This is a parsing bug of MediaWiki on this wiki; this won't occur with a regular HTML parser. As I said, plain HTML links are not supported by Mediawiki as Mediawiki incorrectly includes the "trailing" quote in it. That's something that MediaWiki should fix as these quotes in HTML are never taken into account, unless they are URL-encoded in HTML.
Note that in HTML both the single quote and the double quotes are valid delimiters for attributes, and which ones are valid as part of the quoted value depends on which delimiting paired quotes are used:
- If attribute values are between double quotes
"...", litteral single quotes
'in the embedded value don't need to be encoded, but double quotes in attribute values have to be HTML-escaped as
"(or only if the value is an URL, they can be URL-encoded as
%22, which won't need any HTML-escapes)
- If attribute values are between single quotes
'...', litteral double quotes
"in the embedded value don't need to be encoded, but single quotes in attribute values have to be HTML-escaped as
'(or only if the value is an URL, they can be URL-encoded as
%27, which won't need any HTML-escapes)
Note that any single quote or double quotes by IS valid in any standalone URL (except for the leading protocol part or the host/domain part, it is valid anywhere in the optional parts: the path, the query string, fragment identifier) or any URI. Inside a standalone URI, there's no support at all for the HTML-encoding, or for the URL-encoding (which depends on the protocol and the target host/domain part in its own URL parser, but noit at all of the HTML-parser!!!).
Here MediaWiki (on this wiki) does not parse the HTML completely correctly and so it does not use the correct HTML-parsing for delimiting attributes, and then it considers the value as if it was between double quotes (no check is made about which effective delimtier is used in the HTML attribute, so it incorrectly accepts the single quote as part of it, then it takes the wrong decision).
This is effectively a bug of MediaWiki (which could be reported given that the MediaWiki should still parse HTML correctly and should be an extension of it), in its own custom parser. But as I said, this message is *not* to be parsed by MediaWiki and will be parsed by a regular HTML parser which makes the correct decision. The bug is bisible on this wiki when viewing the translated page, but it does not affect the application.