සැකිල්ල:NVR url

විකිපීඩියා වෙතින්
Jump to navigation Jump to search
ප්‍රලේඛනය අයිකොනය සැකිලි ප්‍රලේඛනය[නරඹන්න] [සංස්කරණය] [ඉතිහාසය] [විරේචනය]

The purpose of this template is to have a single location for the Naval Vessel Register (NVR) ship detail base url as a method of combating link rot.

Usage[සංස්කරණය]

The template takes two parameters:

|id= – (required) the ship's case-insensitive hull classification symbol in one of five forms:
  1. SSBN-659 – the preferred format because it matches the format for hull classification symbols generally used for US Navy ships throughout Wikipedia
  2. SSBN 659
  3. SSBN659
  4. SSBN_659
  5. SSBN_659_1635 – the NVR file name format as of September 2017
There are exceptions. USS Ponce (AFSB (I)-15) has a unique hull classification symbol that must be used in this template exactly as shown. There are three ships listed at the NVR website that do not have hull classification symbols. These are: USS Constitution, USS Maine, and USS Texas. For these three ships, use the ship's name for this parameter. The code word OLDIRON, previously used to identify Constitution, is no longer supported.
|title= – (optional) a title or label for an external link

Parameter names are not required. When not used, the positional order is:

{{NVR url|id|title}}

When |title= is empty or omitted, the template produces a url suitable for use in Citation Style 1 and Citation Style 2 templates.

{{cite web |title=USS Zumwalt |website=Naval Vessel Register |url={{NVR url|DDG-1000}} |accessdate=1 October 2016}}
"USS Zumwalt". Naval Vessel Register. Retrieved 1 October 2016.

With a title, the template produces a properly marked up external wikilink:

{{NVR url|DDG-1000|USS ''Zumwalt''}}
[http://www.nvr.navy.mil/SHIPDETAILS/SHIPSDETAIL_DDG_1000.HTML USS ''Zumwalt'']
USS Zumwalt

There are three ships listed at the NVR website that do not have hull classification symbols. These are: USS Constitution, USS Maine, and USS Texas. For these three ships, use the ship's name for this parameter. The code word OLDIRON, previously used to identify Constitution, is no longer supported.

{{NVR url|constitution|USS ''Constitution''}}
[http://www.nvr.navy.mil/SHIPDETAILS/SHIPSDETAIL_1315.HTML USS ''Constitution'']
USS Constitution


Error messages[සංස්කරණය]

Module:NVR returns error messages when it cannot return a link into the NVR. These error messages are:

  1. required parameter missing – displayed when |id= is empty or omitted from the template call; add a hull classification symbol
  2. malformed hull classification symbol: id – the value assigned to |id= is not one of the supported hull classification symbol forms; use a supported form
  3. unable to find group: ['hull type'] in Module:NVR/data nvr_ships_id – the data tables used by the template are grouped by hull type (the letter portion of a hull classification symbol). This error message indicates that the hull type could not be found in the data table. Check for a typo or, if a new hull type, add the hull type data to Module:NVR/data (further instructions there)
  4. unable to find hull classification symbol: [id] in Module:NVR/data nvr_ships_id – the hull classification symbol value assigned to |id= was not found in the data tables; check for a typo in the number portion of the hull classification symbol or, if a new ship, add the ship data to Module:NVR/data (further instructions there)
  5. no identifier for hull classification symbol: [id] in Module:NVR/data nvr_ships_id – the tables in Module:NVR/data have a listing for the ship but the listing is incomplete; add the missing data to Module:NVR/data (further instructions there)

Errors occurring on main-space pages are categorized at Cat:WPSHIPS:Template errors.

See also[සංස්කරණය]

සැකිල්ල:WPSHIPS Ship citation templates

"https://si.wikipedia.org/w/index.php?title=සැකිල්ල:NVR_url&oldid=445820" වෙතින් සම්ප්‍රවේශනය කෙරිණි