User:SMcCandlish/sandbox21

The tooltip text must be plain text, no links or other markup
Do not link, or use any other wikimarkup or HTML markup, in the meaning (popup tooltip) – only plain text.

The mouse-over tooltip for the meaning text is created by a  attribute inside an  (or, for, ) HTML element's opening tag, so it cannot itself contain any HTML (or markup that resolves to HTML when rendered). This includes simple things like.

Linking in the term
The "term" (abbreviation in, or other inline material in ) can be linked, but this needs to be done one of three ways: Linking inside the template will often not have the intended result:
 * 1) Link  the template:
 * 2) * code:
 * 3) * result: UN
 * 4) * code:
 * 5) * result: conflict of interest


 * UN
 * Conflict of interest

This was not advised because of a Chrome bug, but it is long since fixed. However, there is a still a problem: the link automatically has a  supplied by MediaWiki (the page name), and this in most browsers will override the tooltip   of the surrounding span. So, the intended tooltip will actually only be available to:
 * 1) screen readers
 * 2) in any graphical browser case in which a link is included but is not the entire term content, in which case the intended tooltip will be available when focus is over the span but is not over the part that is a link.
 * 3) in a graphical browser that doesn't treat link  s as tooltip but only as something to show in some other interface element such as the window footer (and here it will not matter if the entire term content is a link or not).

To wiki-link the abbreviation being marked up by this template, wrap the template in the link, not vice-versa, or the meaning will not appear in some browsers, including Chrome.

For this reason, the template instructions to prefer wrapping the template in the link should be retained, along with addition of the new three-parameter version.

TESTING:

Current template output:

conflict of interest

Output, weird: conflict of interest  &#160;&#91;Tooltip: in the specific sense employed in Wikipedia policy&#93;

Output, working in testcases page:

conflict of interest  &#160;&#91;Tooltip: in the specific sense employed in Wikipedia policy&#93;