Template:Book: Difference between revisions

From The Reed and Rite
mNo edit summary
m Renamed parameters.
 
(25 intermediate revisions by the same user not shown)
Line 5: Line 5:
-->| data_rows =<!--
-->| data_rows =<!--
-->{{#if: {{{author|}}} |<tr class="infobox-data-row"><th>Author</th><td>{{{author}}}</td></tr>}}<!--
-->{{#if: {{{author|}}} |<tr class="infobox-data-row"><th>Author</th><td>{{{author}}}</td></tr>}}<!--
-->{{#if: {{{audio|}}} |<tr class="infobox-data-row"><th>Audio Read By</th><td>{{{audio}}}</td></tr>}}<!--
-->{{#if: {{{cover_artist|}}} |<tr class="infobox-data-row"><th>Cover Artist</th><td>{{{cover_artist}}}</td></tr>}}<!--
-->{{#if: {{{spouse|}}} |<tr class="infobox-data-row"><th>Spouse</th><td>{{{spouse}}}</td></tr>}}<!--
-->{{#if: {{{series|}}} | <tr class="infobox-data-row"><th>Series</th><td>{{#if:{{b|{{{series}}}}} | ''[[{{b|{{{series}}}}}|{{b|{{{series}}}|text=y}}]]'' | {{{series}}}}}</td></tr>}}<!--
-->{{#if: {{{parents|}}} |<tr class="infobox-data-row"><th>Parents</th><td>{{{parents}}}</td></tr>}}<!--
-->{{#if: {{{period_covered|}}} |<tr class="infobox-data-row"><th>Period Covered</th><td>{{{period_covered}}}</td></tr>}}<!--
-->{{#if: {{{children|}}} |<tr class="infobox-data-row"><th>Children</th><td>{{{children}}}</td></tr>}}<!--
-->{{#if: {{{publication_date|}}} |<tr class="infobox-data-row"><th>Publication Date</th><td>{{{publication_date}}}</td></tr>}}<!--
-->{{#if: {{{relatives|}}} |<tr class="infobox-data-row"><th>Relatives</th><td>{{{relatives}}}</td></tr>}}<!--
-->{{#if: {{{publication_place|}}} |<tr class="infobox-data-row"><th>Publication Place</th><td>{{{publication_place}}}</td></tr>}}<!--
-->{{#if: {{{profession|}}} |<tr class="infobox-data-row"><th>Profession</th><td>{{{profession}}}</td></tr>}}<!--
-->{{#if: {{{publisher|}}} |<tr class="infobox-data-row"><th>Publisher</th><td>{{{publisher}}}</td></tr>}}<!--
-->{{#if: {{{titles|}}} |<tr class="infobox-data-row"><th>Titles</th><td>{{{titles}}}</td></tr>}}<!--
-->{{#if: {{{media_type|}}} |<tr class="infobox-data-row"><th>Media Type</th><td>{{{media_type}}}</td></tr>}}<!--
-->{{#if: {{{monikers|}}} |<tr class="infobox-data-row"><th>Monikers</th><td>{{{monikers}}}</td></tr>}}<!--
-->{{#if: {{{pages|}}} |<tr class="infobox-data-row"><th>Pages</th><td>{{{pages}}}</td></tr>}}<!--
-->{{#if: {{{groups|}}} |<tr class="infobox-data-row"><th>Groups</th><td>{{{groups}}}</td></tr>}}<!--
-->{{#if: {{{word_count|}}} |<tr class="infobox-data-row"><th>Word Count</th><td>{{{word_count}}}</td></tr>}}<!--
-->{{#if: {{{introduced|}}} |<tr class="infobox-data-row"><th>Introduced</th><td>{{{introduced}}}</td></tr>}}<!--
-->{{#if: {{{audiobook_length|}}} |<tr class="infobox-data-row"><th>Audiobook Length</th><td>{{{audiobook_length}}}</td></tr>}}<!--
-->{{#if: {{{first_mentioned|}}} |<tr class="infobox-data-row"><th>First Mentioned</th><td>{{{first_mentioned}}}</td></tr>}}<!--
-->{{#if: {{{narrated_by|}}} |<tr class="infobox-data-row"><th>Narrated By</th><td>{{{narrated_by}}}</td></tr>}}<!--
-->{{#if: {{{last_mentioned|}}} |<tr class="infobox-data-row"><th>Last Mentioned</th><td>{{{last_mentioned}}}</td></tr>}}
-->{{#if: {{{genre|}}} |<tr class="infobox-data-row"><th>Genre</th><td>{{{genre}}}</td></tr>}}<!--
}}<!--
-->{{#if: {{{isbn|}}} |<tr class="infobox-data-row"><th>ISBN</th><td>{{{isbn}}}</td></tr>}}<!--
-->{{#ifeq:{{NAMESPACE}}|{{ns:0}}|[[Category:Characters]]}}</includeonly><noinclude>
-->{{#if: {{{preceded_by|}}} | <tr class="infobox-data-row"><th>Preceded By</th><td>{{#if:{{b|{{{preceded_by}}}}} | ''[[{{b|{{{preceded_by}}}}}|{{b|{{{preceded_by}}}|text=y}}]]'' | {{{preceded_by}}}}}</td></tr>}}<!--
 
-->{{#if: {{{followed_by|}}} | <tr class="infobox-data-row"><th>Followed By</th><td>{{#if:{{b|{{{followed_by}}}}} | ''[[{{b|{{{followed_by}}}}}|{{b|{{{followed_by}}}|text=y}}]]'' | {{{followed_by}}}}}</td></tr>}}<!--
<noinclude>
-->}}<!--
-->{{#ifeq:{{NAMESPACE}}|{{ns:0}}|[[Category:Books]]}}</includeonly><noinclude>
== Description ==
== Description ==
This template should be used on book pages to add an infobox in the upper right hand corner the article.
This template should be used on book pages to add an infobox in the upper right hand corner of the article.


== Usage ==
== Usage ==
The template has several [[:Template:Character#Parameters|parameters]] that can be used.  
This template has several [[:Template:Character#Parameters|parameters]] that can be used.  
: '''Note: Only fields that are provided will appear in the infobox. Not all parameters are required for each character.'''
: '''Note: Only parameters that are provided will appear in the infobox. Not all parameters are required for each book.'''


{| style="width: 100%; text-align: left; margin: auto;" class="wikitable"
{| style="width: 100%; text-align: left; margin: auto;" class="wikitable"
Line 33: Line 34:
!You Get
!You Get
|-
|-
| style="text-align: left; background-color: white; vertical-align: top;" |<pre>
| style="text-align: left; vertical-align: top;" |<pre>
{{book
{{book
|name=Book Title
|name=Example Book Infobox
|image=FILENAME.EXTENSION
|image=Emma - Volume 1.jpg
|caption=Caption Here
|caption=Caption Here
|author=Author's Name
|author=Author's Name
|audio_read_by=Reader's Name
|cover_artist=Artist's Name
|series=Series Name
|series=Series Name
|period covered=Time Period
|period covered=Time Period
|publication_date=Date Here
|publication_date=Date Here
|publication_place=Location here
|publication_place=Location Here
|publisher=Publisher here
|publisher=Publisher Here
|media_type=Format Here
|media_type=Format Here
|pages=Page Numbers
|pages=Number of Pages
|word_count=Word Count
|audiobook_length=Length of Audiobook
|narrated_by=Reader's Name(s)
|genre=Genre Here
|genre=Genre Here
|isbn=ISBN Here
|isbn=ISBN Here
Line 53: Line 57:
}}
}}
</pre>
</pre>
| style="background-color: white;" |<br>{{book
|<br>{{book
| name = Example Book Infobox
|name=Example Book Infobox
| image = Emma - Volume 1.jpg
|image=Emma - Volume 1.jpg
| caption = Caption Here
|caption=Caption Here
| author = Date of Birth
|author=Author's Name
| audio = Date of Death
|cover_artist=Artist's Name
| spouse = Spouse's Name
|series=Series Title
| parents = Parent Names
|period covered=Time Period
| children = Children Names
|publication_date=Date Here
| relatives = Relatives Names
|publication_place=Location Here
| profession = Profession Here
|publisher=Publisher Here
| titles = Titles Here
|media_type=Format Here
| monikers = Monikers Here
|pages=Number of Pages
| groups = Group Affiliations
|word_count=Word Count
| introduced = First Appearance
|audiobook_length=Length of Audiobook
| first_mentioned = First Mentioned
|narrated_by=Reader's Name(s)
| last_mentioned = Last Mentioned
|genre=Genre Here
|isbn=ISBN Here
|preceded_by=Title Here
|followed_by=Title Here
}}
}}
|}
|}


=== Parameters ===
=== Parameters ===
{| class="wikitable" style="width: 65%;"
{| class="wikitable" style="width: 90%;"
! Parameter !! Description
! Parameter !! Description
|-
|-
| style="text-align: center;" | <code>name</code> || The character's name.
| style="text-align: center;" | <code>name</code> || The book's title.
|-
|-
| style="text-align: center;" | <code>image</code> || Filename of the character's image (e.g., `File:Example.jpg`).
| style="text-align: center;" | <code>image</code> || Filename of the book's cover image (e.g., 'Example.jpg`).
|-
|-
| style="text-align: center;" | <code>caption</code> || Caption for the image.
| style="text-align: center;" | <code>caption</code> || Caption for the image.
|-
|-
| style="text-align: center;" | <code>born</code> || The character's date of birth.
| style="text-align: center;" | <code>author</code> || The author's name.
|-
|-
| style="text-align: center;" | <code>died</code> || The character's date of death (if applicable).
| style="text-align: center;" | <code>cover_artist</code> || The name of the artist who created/designed the cover.
|-
|-
| style="text-align: center;" | <code>spouse</code> || The character's spouse (if applicable).
| style="text-align: center;" | <code>audio_by</code> || The name(s) of who read the audiobook.
|-
|-
| style="text-align: center;" | <code>parents</code> || The character's parents.
| style="text-align: center;" | <code>series</code> || The series the book is from, if applicable. Use abbreviation(s) from [[:Template:B]].
|-
|-
| style="text-align: center;" | <code>children</code> || The character's children.
| style="text-align: center;" | <code>publication_date</code> || The date of publication of first edition.
|-
|-
| style="text-align: center;" | <code>relatives</code> || Other relatives of the character.
| style="text-align: center;" | <code>publication_place</code> || The country where the book was first published.
|-
|-
| style="text-align: center;" | <code>profession</code> || The character's profession.
| style="text-align: center;" | <code>publisher</code> || The name of the publisher. (e.g., Rhysdon Press)
|-
|-
| style="text-align: center;" | <code>titles</code> || Titles or honorifics the character holds.
| style="text-align: center;" | <code>media_type</code> || The forms in which the book has been published. (e.g., Paperback, Hardcover, ebook, audiobook, etc.)
|-
|-
| style="text-align: center;" | <code>monikers</code> || Alternate names or nicknames for the character.
| style="text-align: center;" | <code>pages</code> || The number of pages in the first edition.
|-
|-
| style="text-align: center;" | <code>groups</code> || Groups or affiliations the character belongs to.
| style="text-align: center;" | <code>word_count</code> || The number of words in the first edition.
|-
|-
| style="text-align: center;" | <code>introduced</code> || Where the character was first introduced (e.g., book, chapter, etc.).
| style="text-align: center;" | <code>audio_length</code> || The length of the audiobook of the first edition.
|-
|-
| style="text-align: center;" | <code>first_mentioned</code> || Where the character was first mentioned (e.g., book, chapter, etc.).
| style="text-align: center;" | <code>genre</code> || The genre of the book.
|-
|-
| style="text-align: center;" | <code>last_mentioned</code> || Where the character was last mentioned (e.g., book, chapter, etc.).
| style="text-align: center;" | <code>isbn</code> || The ISBN number of the first edition.
|-
| style="text-align: center;" | <code>preceded_by</code> || What book came before the book, if applicable. Use abbreviation(s) from [[:Template:B]].
|-
| style="text-align: center;" | <code>followed_by</code> || What book came after the book, if applicable. Use abbreviation(s) from [[:Template:B]].
|}
|}


== Articles using Template ==
== Articles using Template ==
:{{for|Special:WhatLinksHere/{{FULLPAGENAME}}|a full listing|here|pre=This list is limited to 100 pages}}
{{for|Special:WhatLinksHere/{{FULLPAGENAME}}|a full listing|here|pre=This list is limited to 100 pages}}
{{Special:WhatLinksHere/{{FULLPAGENAME}}|namespace=0|limit=100}}
{{Special:WhatLinksHere/{{FULLPAGENAME}}|namespace=0|limit=100}}
[[Category:Infoboxes]]
{{Book
| title = Example InfoBox
| image = Emma - Volume 1.jpg
| caption = Caption Here
| author = Author's Name
| audio_read_by = Reader's Name
| series = Series Name
| period covered = Time Period
| publication_date = Date Here
| publication_place = Location here
| publisher = Publisher here
| media_type = Format Here
| pages = Page Numbers
| genre = Genre Here
| isbn = ISBN Here
| preceded_by = Title Here
| followed_by = Title Here
}}
== Usage ==
This is a generic infobox for books. Only fields that are provided will appear in the infobox.
=== Parameters ===
* `title` (required): The book's title.
* `image`: Filename of the book cover image (e.g., `File:Example.jpg`).
* `caption`: Caption for the image.
* `author`: Author of the book.
* `audio_read_by`: The narrator of the audiobook (if applicable).
* `series`: Series the book belongs to.
* 'period covered': Period of time covered in book.
* `publication_date`: Date the book was published.
* `publication_place`: Place where the book was published.
* `publisher`: The book's publisher.
* `media_type`: The format (e.g., Hardcover, Paperback, eBook, Audiobook).
* `pages`: Number of pages in the book.
* `genre`: The book's genre.
* `isbn`: The ISBN of the book.
* `preceded_by`: Previous book in the series (if applicable).
* `followed_by`: Next book in the series (if applicable).


[[Category:Infoboxes]]
[[Category:Infoboxes]]

Latest revision as of 22:32, 7 July 2025

Description

This template should be used on book pages to add an infobox in the upper right hand corner of the article.

Usage

This template has several parameters that can be used.

Note: Only parameters that are provided will appear in the infobox. Not all parameters are required for each book.
You Type You Get
{{book
|name=Example Book Infobox
|image=Emma - Volume 1.jpg
|caption=Caption Here
|author=Author's Name
|cover_artist=Artist's Name
|series=Series Name
|period covered=Time Period
|publication_date=Date Here
|publication_place=Location Here
|publisher=Publisher Here
|media_type=Format Here
|pages=Number of Pages
|word_count=Word Count
|audiobook_length=Length of Audiobook
|narrated_by=Reader's Name(s)
|genre=Genre Here
|isbn=ISBN Here
|preceded_by=Title Here
|followed_by=Title Here
}}

Example Book Infobox
Caption Here
Caption Here
Caption Here
AuthorAuthor's Name
Cover ArtistArtist's Name
SeriesSeries Title
Publication DateDate Here
Publication PlaceLocation Here
PublisherPublisher Here
Media TypeFormat Here
PagesNumber of Pages
Word CountWord Count
Audiobook LengthLength of Audiobook
Narrated ByReader's Name(s)
GenreGenre Here
ISBNISBN Here
Preceded ByTitle Here
Followed ByTitle Here

Parameters

Parameter Description
name The book's title.
image Filename of the book's cover image (e.g., 'Example.jpg`).
caption Caption for the image.
author The author's name.
cover_artist The name of the artist who created/designed the cover.
audio_by The name(s) of who read the audiobook.
series The series the book is from, if applicable. Use abbreviation(s) from Template:B.
publication_date The date of publication of first edition.
publication_place The country where the book was first published.
publisher The name of the publisher. (e.g., Rhysdon Press)
media_type The forms in which the book has been published. (e.g., Paperback, Hardcover, ebook, audiobook, etc.)
pages The number of pages in the first edition.
word_count The number of words in the first edition.
audio_length The length of the audiobook of the first edition.
genre The genre of the book.
isbn The ISBN number of the first edition.
preceded_by What book came before the book, if applicable. Use abbreviation(s) from Template:B.
followed_by What book came after the book, if applicable. Use abbreviation(s) from Template:B.

Articles using Template