Wikibooks:Userboxes

From Wikibooks, open books for an open world
Jump to: navigation, search
Crystal kthememgr.svg A userbox is a small box that looks like this.
Userboxes can come in many different styles and colors. Crystal package.png
Crystal package favourite.png Userboxes can have one or two sideboxes. Ark-icon.png

Userboxes (commonly abbreviated as UBX) are small colored boxes that allow users to add small messages on their user pages. They generally include one or two small graphics and a few short lines of text. Often they also include wiki markup that places the user in a category. Userboxes are generally created as templates and transcluded onto userpages, although their markup may be substituted directly onto user pages instead. Userboxes should not be used in articles.

The primary purpose of userboxes and user categories should be to alert other Wikibookians to ways you might aid them in editing. For instance, if you speak a second language or have professional expertise in a technical field, other users will know they can contact you for assistance.

Acceptable uses for boxes include user interests, user skills, technical information, or Wikibooks activities. Do not create or use boxes that do not add to the Wikibooks community. Userboxes should themselves be filed in a category, but they should not always file those that use them in a category. Keep in mind the existing categories when determining whether a userbox should do so or not.

Using existing userboxes[edit]

Userboxes are for the use of users on their own user pages. It may be considered uncivil to place any userboxes on any other user(s)'s page(s) without their permission.

The standard syntax for adding a userbox to your user page (also known as transclusion) is: {{user nameofbox}}.

Creating a new userbox[edit]

Any userbox, especially those of a more personal nature, should be created as a sub-page of your user page rather than placing it in the Template: namespace.

Userbox names in the Template: namespace must begin with "User " (for example, Template:User nameofbox). Those in Template: namespace may be expected to adhere more tightly with the acceptable uses illustrated above compared to ones that are subpages to your user page, which is given more leeway than content in other namespaces.

Content restrictions[edit]

    • Userboxes must not include blatant incivility or personal attacks.
    • Userboxes must not be intentionally inflammatory or divisive.
    • Wikibooks is not an appropriate place for political campaigning.
    • Userboxes which imply a negative attribute of some person or group to which the userbox creator then expresses objection, are not usually acceptable.

Simply: If content is not appropriate on a user page, it is not appropriate within userboxes.

Caution about image use[edit]

  • The Wikimedia Commons has a large range of icons for use within boxes. However, if you wish to select a different image to put in a userbox, make certain the image license is free. WikiBooks policy does not allow templates (which includes userboxes) or user pages to contain any copyrighted content not under free license; so, for example, "fair use" images are explicitly forbidden. This clause is to be interpreted strictly and without exception, for legal reasons.

Caution about user categories[edit]

  • Userboxes that include Category markup which adds the bearing userpage to a category must only categorize within subcategories of Category:Wikibookians.
  • Names and descriptions of subcategories are subject to the same rules and restrictions as userbox content.
  • Userboxes should not automatically include categories by default. Consider how useful the category would be to other editors before adding it to your userbox.
  • Do not create categories which could potentially include all Wikibookians. For example, userboxes such as: "This user is a Wikibookian."; "This user is human."; "This user uses the internet"; etc., should not include category markup based on such criteria.
  • Avoid categorizing "not"-based userboxes. For example: "This user does not like <noun phrase>."

Content examples[edit]

Typical userbox content examples:

  • This user <verb phrase> <noun phrase>
    • This user is <noun phrase>
    • This user is a member of <noun phrase>
    • This user is a fan of <noun phrase>
    • This user supports <noun phrase>
    • This user contributes to <noun phrase>
    • This user is interested in <noun phrase>
    • This user is fascinated by <noun phrase>

Other combinations are obviously possible.

Other typical verbs (again, others are possible): drives, eats, edits, enjoys, favors, likes, loves, plays, prefers, reads, speaks, understands, uses, and watches.

Avoid the following verbs: considers, finds, knows, and thinks.

Also avoid compound sentences which are positive and negative, such as:

  • This user likes <noun phrase>, but does not like <another noun phrase>.

Constructing a userbox[edit]

There are a number of box types to select from when deciding to make a userbox. The most commonly used design is the "Standard box". It has one square shaped area on the left ("id") and a rectangular area on the right ("info").

For ease of use, userboxes are made using maker-templates that have a number of parameters. Once the maker-template is saved, it is automatically transformed to HTML.

Template Parameters Meaning Value type
border-c The border color of the userbox. CSS color value (#hex or color name)
border-s The border size of the userbox. Width in pixels
id-c The background color of the id box. CSS color value
id-s The font size of the id box. Size in PostScript points
id-fc The font color of the id box text. CSS color value
id-p The distance between border and content of id box. CSS padding width value. px, pt
id-lh The distance between text lines of id box. CSS relative line height/length value. em
info-c The background color of info box. CSS color value
info-s The font size of info box. Size in PostScript points
info-fc The font color of info box. CSS color value
info-p The distance between border and content of info box. CSS padding width value. px, pt
info-lh The distance between text lines of info box. CSS relative line height/length value. em
id This is the content of the id box. Text
info This is the content of info box. Text

Userbox types[edit]

Code Appearance
Standard box (Template:Userbox)
{{Userbox |border-c=#000 |border-s=1 |id-c=#fff |id-s=12 |id-fc=#000 |info-c=#039 |info-s=8 |info-fc=#fff |id=K |info=Content}}

or {{Userbox |side-box color |main box color |side-box content |main box content}}

ID Content
Reverse box (Template:Userbox-r)
{{Userbox-r |border-c=#000 |border-s=1 |id-c=#fff |id-s=12 |id-fc=#000 |info-c=#039 |info-s=8 |info-fc=#fff |id=ID |info=Content}}

or {{Userbox-r |side-box color |main box color |side-box content |main box content}}

Content ID
Double box (Template:Userbox-2)
{{Userbox-2 |border-c=#000 |border-s=1 |id1-c=#fff |id1-s=12 |id1-fc=#000 |id2-c=#000 |id2-s=12 |id2-fc=#fff |info-c=#039 |info-s=8 |info-fc=#fff |id1=ID 1 |id2=ID 2 |info=Content}}

or {{Userbox-2 |side-box 1 color |main box color |side-box 1 content |message |side-box 2 content |border color |side-box 2 color |main box font-color |box border thickness}}
Note: If omitted, border color and side-box 2 color default to the same color as side-box 1, and font color is black. Default border thickness is 1.

ID 1 Content ID 2

Gallery[edit]

Languages[edit]

Interests and tastes[edit]

Life, status, and situation[edit]

Wikibooks-related[edit]

Miscellaneous[edit]