Jump to content

Template talk:BOOKNAME

Page contents not supported in other languages.
Add topic
From Wikibooks, open books for an open world
Latest comment: 5 years ago by Pi zero in topic Safesubst

include user?

[edit source]

Is there anyhing to be said against to take up also the ARTICLESPACE "user"? If not, the Template:ROOTBOOKNAME2 would not be needed by the Template "toto". --Mjchael (talk) 11:48, 15 August 2009 (UTC)Reply

I've added this to the template for you. -- Adrignola talk contribs 12:14, 15 August 2009 (UTC)Reply
Thank you!
But sorry, I found another: "Transwiki". From Transwiki:Bypassing the Great Firewall of China. I guess, soon it will be merged into Bypassing Internet Censorship. I thought about "Wikijunior", but it seem to be not helpful, because it makes sense to know, that this is a "Wikijunior-Book". --Mjchael (talk) 12:39, 15 August 2009 (UTC)Reply

The new behavior of {{ROOTBOOKNAME}} on userspace — and its old behavior on userspace as well — strike me as inconsistent with the purpose of {{ROOTBOOKNAME}}. (We'd never really given a long hard look to the behavior of {{ROOTBOOKNAME}} on namespaces other than main, Wikijunior, template, and category — until now this has pushed me into really focusing on it.) Software tools should have a single clear purpose and do that one thing really well; in my experience, trying to shoehorn multiple, partly disparate purposes into a single tool never ends well.

The purpose of {{ROOTBOOKNAME}} is to extract, from the current page name, the name of the book with which the current page is administratively associated, even if that associated book is in a different namespace. For categories and templates, that means stripping off the namespace prefix, so for example Template:Wikijunior:Solar System/Coolfacts is associated with book Wikijunior:Solar System. For pages that are actually parts of books, the namespace prefix is kept, so for example Wikijunior:Languages/Klingon is associated with book Wikijunior:Languages. Thus {{ROOTBOOKNAME}} partitions (non-talk) namespaces into those that are part of book names, and those that aren't. The ones that aren't are considered to be special administrative namespaces, and therefore exceptions to the rule (which is why the default is to strip off keep the namespace prefix). Heuristically, the exceptional, administrative namespaces are recognized by two characteristics: they don't host books, and it is possible to imagine a page in that namespace having a name that associates it with a book in any of several other namespaces.

What about userspace? I'm willing to stipulate that no book would ever be hosted in userspace. However, if a page associated with, say, Wikijunior:Solar System were located in userspace, its name would not start with  User:Wikijunior:Solar System, but rather with  User:name/Wikijunior:Solar System. For example, if {{ROOTBOOKNAME}} were called from anywhere on a page  User:Pi zero/Wikijunior:Solar System/Print version, it should produce  Wikijunior:Solar System. That's {{ROOTBOOKNAME}}'s reason for existing.

If that behavior would actually be reasonable for the way {{ROOTBOOKNAME}} is being used in {{Todo}}, then that's well and good. If that behavior isn't reasonable for the way {{ROOTBOOKNAME}} is being used in {{Todo}}, then, on sober reflection, {{Todo}} shouldn't be using {{ROOTBOOKNAME}}.

BTW, it seems reasonable to me to treat  Transwiki:  as a purely administrative prefix, to be stripped off by {{ROOTBOOKNAME}}, because pretty clearly transwiki-space would never host a book (though it probably also wouldn't contain a page whose name adminstratively associated it with a book in another space).

Now that this has come up, I'm thinking sometime soon I should draft a proposed upgrade for {{ROOTBOOKNAME}}, encompassing both its behavior and its documentation. --Pi zero (talk) 18:55, 15 August 2009 (UTC)Reply

Renamed

[edit source]

I've renamed this template from ROOTBOOKNAME to BOOKNAME. The shuffling around of templates and the history behind it are described in a reading room thread.) --Pi zero (discusscontribs) 03:01, 26 January 2018 (UTC)Reply

Safesubst

[edit source]

Add safesubst: in the text. 64.114.239.29 (discuss) 19:24, 11 September 2019 (UTC)Reply

I've never tangled with safesubst, though of course I'm peripherally aware of it. Was under the impression that would require obnoxious repetitions at every level of nested template calls. --Pi zero (discusscontribs) 23:37, 11 September 2019 (UTC)Reply