Using Wikibooks/Subjects, Categories, and Classifications

< Using Wikibooks

If you've read Finding A Wikibook, then you see that there are many ways to find a Wikibook on the topic of your choice. However, whether starting a new book or expanding heavily on a book that is merely a stub, you need to ensure that your book is visible to both readers and potential contributors. The terminology used in Wikibooks for the various methods of organization can be confusing, and the proper implementation of those methods on your book can be even harder to grasp. After reading the following sections you should have a better idea how this all works.

To help make the entire book visible to readers and potential contributors, most books have:

Subjects and categories

As a reader, browsing the subject pages allows you to find books on the topic of your choice. As a writer, you have an interest in having your book appear in the subject of your choice. The subject pages are dynamically generated, meaning you cannot add your book to a subject page directly to have it appear there. Each subject page has wiki markup in it that specifies a certain category to look in for pages that will be then displayed on the subject page. When you file your book's main page in that special category, it will appear on the corresponding subject page, and on the subject pages of larger subjects containing that subject. The details of how to do this are explained later.

The pages of your book also need to be filed in a category, but they should not be filed in the special category that matches up to the subject in which you are filing the main page of your book. If they were, every page of your book would show up on the subject page, overwhelming all the other books and destroying the value of the subject page. Instead, they should be filed in a category whose name is the title of your book. The details of this are explained below.

Keeping these two types of categories straight is important. The category a book's main page is filed in is often referred to as a subject category, since anything filed in it appears in a subject page. The category the rest of the book's pages are filed in is referred to as a book category, since everything filed in it should pertain only to a single book. Several naming conventions prevent confusion between book categories and subject categories. The name of a subject category has a Subject: prefix, followed by exactly the name of the corresponding subject; the name of a book category is exactly the name of the book's main page. Also, by convention, subjects have been named using Sentence case, while books are normally titled using Title Case. For example, there is (as of this writing) a book Emergency Medicine and a subject Emergency medicine; the book main page is Emergency Medicine, the subject page is Subject:Emergency medicine, the book category is Category:Emergency Medicine, and the subject category is Category:Subject:Emergency medicine.

Filing your book's main page

Your book's main page is key to having your book be found by those who would have an interest in it. Several pieces of code need to be added to it for your book to appear both on subject pages and on pages used for other methods of finding books.

Subject category

If you have spent the time determining your book's subject matter and scope, then you will have an easier time determining what subject category to file it in. The top-level subjects all contain more specific subjects within them. Only in the rarest of cases will your book be filed in a top-level subject category, and if you believe it belongs there you should consider narrowing the scope of the book. A book needs to be placed in the most specific subject possible, and usually only needs to be placed in one subject. A more specific subject is one of many that are encompassed by a less specific subject, so there is no need to file a book in both. For instance, a book filed in Subject:Constructed languages does not also need to be filed in Subject:Languages since the former is one of many subjects that are part of the latter.

Also, file your book based on the topic it actually covers and not topics that would only be related tangentially. For example, a book filed in Subject:Educational software should not be filed in Subject:Microsoft Windows as well simply because it covers a program that runs on Windows.

The hard part is figuring out what subject best matches your book's content. The easy part is actually putting the main page in the subject category that corresponds to the subject page you want it to show up in. Simply place {{Subjects|Foo}} or {{Subjects|Foo|Bar}} on the bottom of your book's main page, where Foo and Bar are subject category names. As mentioned earlier, less is more, so do not overdo it.

Alphabetical classification

The alphabetical classification system allows people to search for a book by the first letter or number in its title. This is especially helpful if someone is looking for several books on the same topic that all start out with the same first word in the title.

The easiest of all the methods you have at your disposal for filing your book, simply add {{Alphabetical|*}} to the bottom of your book's main page, where * is the first letter or number in your book's title. Use your discretion as to whether to count the words "A" or "The" as the first words of your title for the purposes of filing. Ideally, if those words are not necessary, they should not be added to the beginning of the title in the first place.

Filing your book's chapters and pages

The rest of the pages of your book should not have any of the above bits of code added to them. They need to be filed, either directly or indirectly, in the category with the same name as your book's title. Directly means that they are filed specifically in that category, while indirectly means they are filed in another category that is itself filed in your book's category. Placing all your pages into a book category allows for an alphabetical index of pages to complement your book's table of contents, without having to generate such an index manually. When you create a new page in your book and add it to your book's category, it automatically appears in this index.

As you learned in How To Structure A Wikibook, your pages can be structured using a flat method or one using chapters. How you file the pages within your book's category also depends on personal preference and the conventions used by your book.

Flat filing

The simplest method of filing your book's pages is to put them all in the category of your book's name directly. If your book's name is Foo Bar the category would be Category:Foo Bar. This could be done with [[Category:Foo Bar]]. This is not the ideal option, however.

The pages should be sorted within the category to make it easier to locate them. If you do not specify the method of this sorting, they will all show up under the first letter of your book's name. Continuing the example of Foo Bar, all the pages would show up under F. Rather than manually specifying sorting on a per-page basis, use the {{BookCat}} template at the bottom of every page to sort the page based on the portion after the title. Foo Bar/Blah would be sorted based on Blah. You can also add {{BookCat}} in a template included on all your pages for the same effect.

You will notice that the category added to the bottom of the pages is red. You need to click it and create the category before it will exist. Add a description to the top of it and preferably also add a link to your book's main page as well. Most importantly, file your book's category in the subject category that your book's main page is filed in. The subject pages do not show categories, only pages, so this allows people viewing a subject's corresponding category to see both your book's main page and your book's individual category.

You can use the very same code you placed on your book's main page {{Subjects|Foo}} or {{Subjects|Foo|Bar}} on the bottom of your book's category, where Foo and Bar are subject category names.

Deep filing (advanced)

If you have structured your book using chapters and a deep structure, you may have hundreds of pages. That many pages in your book's category can become unwieldy. The more advanced option is to file pages within each chapter inside separate categories that are in turn filed in your book's category. This technique can be understood better by using an example. Take a book with the following pages (not as many as would actually be used for this method):

My Book
My Book/Foo My Book/Bar
My Book/Foo/Page My Book/Bar/Page

Category:My Book would still exist and be filed in the same subject category as the book, as with flat filing. However, additional categories would be created for all the pages under Foo and Bar, with those categories filed in Category:My Book. Pages in the Foo chapter would be in Category:My Book/Foo and pages in the Bar chapter would be in Category:My Book/Bar.

The code used for this method is similar to that used in the flat filing method. Add {{BookCat|filing=deep}} to the bottom of the pages or in a template placed on all the pages, which will automatically file the pages into subcategories of the root book category. The pages will be sorted based on the first letter of the page rather than the chapter and all the pages of the same chapter are inside a unique category.

When creating the categories for each chapter's pages by clicking the red link that appears at the bottom of the page, add the category to the book's category with {{BookCat}}. This puts the chapter category into the book's category and sorts it based on the chapter's name, rather than the first letter of the book's name.

You can use this technique if you have many templates in use by your book as well. If My Book had several templates, it could use Category:My Book/Templates for even more control. Templates can be filed by having {{BookCat}} placed inside the template, which will ignore the Template: portion of their name when sorting them inside of a /Templates subcategory. Add the template subcategory to your book's category with {{BookCat}} on the bottom of the category page.

To conclude the demonstration by example, Category:My Book would end up looking like the following using deep filing:

Category:My Book
My Book
My Book/Foo
My Book/Bar
Category:My Book/Foo
My Book/Foo/Page
Category:My Book/Bar
My Book/Bar/Page
Category:My Book/Images
Category:My Book/Templates
This article is issued from Wikibooks. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.