Jump to content

Template talk:Format ISBN

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
(Redirected from Module talk:Format ISBN)

9 digits

[edit]

I'm debating whether to have the template interpret 9-digit input as an older-than-old-school Standard Book Number, rather than an error, as long as the check digit seems correct. Demand for that may be too limited to bother. ―cobaltcigs 08:51, 16 March 2020 (UTC)[reply]

redeployed

[edit]

This template was deleted as the result of a discussion at Wikipedia:Templates for discussion/Log/2022 November 18 § Template:Format ISBN. Discussion at Wikipedia talk:ISBN § Hyphens in ISBNs suggested that there is a desire for the functionality of the template, so I have restored it and Module:Format ISBN and Module:Format ISBN/data (with modifications).

The original template formatted its input and then, by default, wrapped the formatted ISBN in wikilink markup so that the result linked to Special:BookSources. Linking could be disabled by using a special parameter. The new version of this template does not link nor does it emit error messages on the assumption that this template will be used inside other templates like {{ISBN}} and the Citation Style 1 and 2 templates in the |isbn= parameter. Both of those templates link to Special:BookSources and both emit error messages when appropriate. The new version also allows editors to choose hyphen character separators (default) or space character separators; the original used hyphens exclusively.

Support exists in Module:Format ISBN for another template (perhaps {{Format ISBN link}} or some such) that does link its output to Special:BookSources and does emit error messages (which can be suppressed):

{{#invoke:Format ISBN|format_linked|template_name=Format ISBN link|9789295055124}}978-92-95055-12-4
{{#invoke:Format ISBN|format_linked|template_name=Format ISBN link|9789295055123}} → 9789295055123  Parameter error in {{Format ISBN link}}: checksum
{{#invoke:Format ISBN|format_linked|template_name=Format ISBN link|9789295055123|suppress-errors=yes}}9789295055123

I don't know of a case where such output is needed that can't be gotten from {{ISBN}}:

{{ISBN|9789295055124|plainlink=yes}}9789295055124

except that those who also want proper formatting won't have to nest {{Format ISBN}} inside {{ISBN}} ({{ISBN|{{Format ISBN|9789295055124}}|plainlink=yes}}).

It could be that {{ISBN}} might be modified to apply formatting 'automatically' if there is sufficient desire for that...

Trappist the monk (talk) 21:50, 22 April 2023 (UTC)[reply]

I would support modification of {{ISBN}} to apply formatting automatically. Ifly6 (talk) 05:05, 23 April 2023 (UTC)[reply]
I think subst'ing is a better approach. Editors are humans too, and will find formatted ISBNs in the wikisource easier to read, check against books, etc. Also, formatting involves a table lookup, and this computation is best done once, rather than for all the ISBNs on a page every time it is loaded. Kanguole 09:58, 24 April 2023 (UTC)[reply]

Template documentation examples and explanations

[edit]

The opening paragraphs/sentences show us 3 examples of incorrect usage. E.g., the ISBNs have the wrong checksums. But WP-editors really need to see correct usage. And with correct examples. The introduction needs to tell us "what happens next" after a correct "Format ISBN" is added to a reference. I.e., a correct Format ISBN will give a result that links to Book sources. (Real life editing from today – I tried adding a "Format ISBN" to an article, but I had difficulty. E.g., I added "{{Format ISBN|3-8053-0042-5}}". After a wait, no bot came along to make the needed change. But when I changed it to "{{ISBN|{{Format ISBN|3-8053-0042-5}}}}" the bot came along and produced the result I wanted – an ISBN-13, with hyphens, that linked to Book sources. If editors see and understand the way this works I think (and hope) they will use it. – S. Rich (talk) 02:43, 25 April 2023 (UTC)[reply]

It is widely acknowledged that I suck at writing template documentation. If you can improve this template's documentation, please do.
Auto-substing isn't instantaneous. Category:Wikipedia templates to be automatically substituted has 1700+ templates that are to be automatically subst'd so it can take a while for the bot to cycle round to this template. How long that takes is likely impacted by server load and perhaps by scheduling. Be patient. If you need substing-right-now you can write: {{subst:Format ISBN|<unformatted ISBN>}} (does not work inside <ref>...</ref> tags).
There is discussion at Wikipedia talk:ISBN § Hyphens in ISBNs that seems to indicate that the forced conversion of ISBN10 to ISBN13 is an undesirable artefact of the current live template so it is likely that that 'feature' will go away – at least as currently implemented. I might consider adding ISBN10 → ISBN13 conversion as an optional parameter if there is sufficient desire.
Trappist the monk (talk) 11:22, 25 April 2023 (UTC)[reply]
I've had a go at revising the documentation. {{ISBN}} is not directly relevant here: it does an independent job, namely linking to Special:BookSources, and has nothing to do with when the bot substitutes {{Format ISBN}}. Kanguole 07:32, 26 April 2023 (UTC)[reply]

Created redirect from Templates 'format isbn', 'fi' (all lowercase), and 'FI'

[edit]

... for the ease of (frequent) typing. – .Raven  .talk 05:52, 15 May 2023 (UTC)[reply]

ISBN formatting

[edit]

Wikipedia:Village pump (policy) § RfC: Standardizing ISBN formatting (and an end to editwarring about it) is a discussion which watchers of this page may be interested in. Izno (talk) 02:16, 1 November 2023 (UTC)[reply]