Help:Cite errors

The BattleTechWiki footnotes system has the ability to detect errors. This page documents the error messages and provides an understanding of the problem and solutions.

Error messages[edit]

The messages will be formatted as an error, and are visible on the rendered page after hitting the "Publish changes" button.

These messages are dependent on the language setting in Special:Preferences— this list applies only to "en — English".

  • Invalid <ref> tag;

refs with no name must have content

  • The opening <ref> tag is malformed or has a bad name
  • Invalid <ref> tag;

invalid names, e.g. too many

  • Invalid <ref> tag;

name cannot be a simple integer. Use a descriptive title

  • Closing </ref> missing for <ref> tag
  • Invalid <ref> tag;

no text was provided for refs named $1

  • Invalid parameter in <references> tag
  • Ran out of custom backlink labels.

Define more in the [[MediaWiki:Cite references link many format backlink labels]] message.

  • <ref> tags exist for a group named "$1", but no corresponding <references group="$1"/> tag was found, or a closing </ref> is missing
  • <ref> tag in <references> has conflicting group attribute "$1".
  • <ref> tag defined in <references> has group attribute "$1" which does not appear in prior text.
  • <ref> tag with name "$1" defined in <references> is not used in prior text.
  • <ref> tag defined in <references> has no name attribute.
  • Invalid <ref> tag; name "$1" defined multiple times with different content
  • <ref> tag defined in <references> with name "$1" has no content.
  • Cite error: $1

Other problems[edit]

Some problems may not show a cite error message, while others may not be obvious.

In ref name use only straight quotation marks[edit]

When you cite the same source more than once on a page, use only straight quotation marks " " to enclose the reference name. Do not use curly quotation marks “ ”, which are treated as simply another character, not as quotation marks. An error message will appear if the original and repeat references use a mix of straight and curly quotation marks. The syntax to define a named reference is:

<ref name="name">content</ref>

To repeat the named reference:

<ref name="name" />

A page shows in the reference error category, but no cite errors show[edit]

If <ref>...</ref> includes a URL with an =, and if the reference is inside a template, then the template will fail. Depending on the placement of the URL, the cite error message may not display, but the page will be included in the error category. Ensure that = are encoded as &#61;

refTools should catch this problem.

For example, an incorrectly nested reference where {{lower}} is being used to make the reference smaller:

{{lower|<ref>content1<ref>content2</ref>[http://www.washingtoninstitute.org/templateC05.php?CID=2386]</ref>}}

Reference links show in the body of the article, but do not show in the reference list[edit]

This may be caused by a template that is not properly closed with }}.

It can also be caused by multiple footnotes that are defined to use the same name. Links will be generated for both, but only the first will show in the references list: For example:

<ref name="foo">content1</ref>
<ref name="foo">content2</ref>

Only content1 will show. refTools will catch this problem.

Content on a non-article page is missing[edit]

If a footnote does not have a closing </ref>, it will "eat" the following text, causing it to not show. This normally shows a cite error, unless it is the last footnote on the page. Normally, this would then suppress the <references /> tag, generating an error, but the message for a missing <references /> tag is suppressed on non-article pages. refTools will catch this problem.


Messages, namespaces and categories[edit]

Internal messages are generated by the Cite.php extension and shown as a MediaWiki message. See the parser hooks section of Special:Version for the installed version of Cite.php. These messages are in the MediaWiki namespace and can be modified only by admins.

The MediaWiki messages use {{broken ref}} to control the namespace and category. Messages show only on main (article), user, template, category, help and file pages. Talk pages do not show error messages.

Category default sorting is by {{PAGENAME}} for the main namespace and by τ{{PAGENAME}} for template, category, help and file namespaces.