Pereiti prie turinio

Naudotojas:Vpovilaitis/refToolbar

Puslapis iš Vikipedijos, laisvosios enciklopedijos.

refToolbar.js is a JavaScript tool that adds an extra button to the editing toolbar for commonly used citation templates - {{cite web}}, {{cite news}}, {{cite book}}, and {{cite journal}}.

Usage[redaguoti | redaguoti vikitekstą]

It will add a "cite" button to the right side of the editing toolbar for citation templates. When you click on the button, you can choose which citation template to use and a form will appear with fields to fill in for available parameters in the citation template. Unfilled parameters will not be added to the page. The templates are already wrapped in <ref> tags. Cite web and cite news will have their "accessdate" parameter filled in with the current UTC date. Click the "add citation" button to add it to the page.

The "Named references" button produces a list of all the named references in the text, for easy addition of repeated references.

Installation[redaguoti | redaguoti vikitekstą]

Gadgets[redaguoti | redaguoti vikitekstą]

You can add the stable version of this script through the Gadgets tab in your user Preferences, click the checkbox for "refTools" under the "Editing gadgets" section, then the "Save" button.

Monobook.js[redaguoti | redaguoti vikitekstą]

Or to use the latest version of the script (may be different from the Gadget version, possibly broken, and not tested as extensively), add

importScript('User:Mr.Z-man/refToolbar.js');

to your monobook JS page (or whatever skin you use) and bypass your cache.

Features[redaguoti | redaguoti vikitekstą]

  • Easily add commonly used citation templates.
  • Ability to add named references already used in the article.
  • Error checking, checks for common citation issues:
    • <ref> tags with no closing </ref>
    • Multiple references that contain the same content
    • References that do not use a citation template (often important for consistency)
    • References assigned the same name
    • Usage of undefined named references

Future features[redaguoti | redaguoti vikitekstą]

  • Better date handling - convert things like "January 1, 2008" into the template-friendly "2008-01-01," if the user doesn't give a full date, use |month= and |year= instead of |date=
    • Automatic date fixing as part of error checking.
  • More templates (everything in the table on WP:CITET?)
    • Something other than buttons to choose templates.
  • Support for reference groups
  • Tooltips?
  • Retrieve named refs from the whole article even if editing just a section (need to do performance checks first, large articles might cause crashes)

Userboxes[redaguoti | redaguoti vikitekstą]

Šablonas:Usbktop Šablonas:Usbk Šablonas:Usbkbottom