Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Editing Battlestar Wiki:CSS

From Battlestar Wiki, the free, open content Battlestar Galactica encyclopedia and episode guide
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision Your text
Line 1: Line 1:
{{Project|CSS|shortcut=BW:CSS}}
{{Project|CSS|shortcut=BW:CSS}}


To help you understand how to use the new "Styles" that have been installed, this reference article has been created to tell you the most basic options on how to create "cross-compatible" elements with all the styles. This happens because each style has their own CSS file and their own colors. So no matter how you look at the elements, they always show up the same way. These are the major ones so that's why they are here.
To help you understand how to use the new "Styles" that have been installed, this reference article has been created to tell you the most basic options on how to create "cross-compatiable" elements with all the styles. This happens because each style has there own CSS file and their own colors. So no matter how you look at the elements, they always show up the same way. These are the major ones so that's why they are here.


== Creating Infoboxes ==
== Creating Infoboxs ==


=== Example ===
=== Example ===
Line 28: Line 28:


=== Example ===
=== Example ===
{{message box
 
|heading= Heading
|message= Message goes here<br/>Message can span multiple lines, but make sure to use <nowiki><br/></nowiki> to separate them.
|id= messagebox1
|image= BSG_WIKI_Project.png
|shortcut= BW:CSS
}}
* Heading: Will appear in bold on top of the message box.
* Message: The content of the message box
* ID: ID of the message box. If set, you can jump to the messagebox with PAGENAME#ID
* Image: The image that should be shown in the left column, without the Image: prefix.
* Shortcut: Contents of the shortcut box. If unset, the shortcut box will be hidden.
=== Code ===
=== Code ===
<pre>
{{message box
|heading= Heading
|message= Message goes here<br/>Message can span multiple lines, but make sure to use <nowiki><nowiki><br/></nowiki></nowiki> to separate them.
|id= messagebox1
|image= BSG_WIKI_Project.png
|shortcut= BW:CSS
}}
</pre>


== Creating Content Boxes ==
== Creation Content Boxes ==


=== Example ===
=== Example ===
Line 79: Line 59:
| class="contentbox"
| class="contentbox"
|-
|-
|}
</pre>
== Creating collapsible tables ==
=== Example ===
{| class="navbox collapsible collapsed" width="100%"
! class="infoboxheader" colspan="2" align="left" | Heading
|-
| Content goes here
|}
* Collapsed: If ''collapsed'' is set, the table will be collapsed initially. If you want the table to be expanded initially, omit collapsed.
* Autocollapse: If ''autocollapse'' is set, the table will only be expanded initially if it's the only collapsible table on the page. If there are more, it'll be collapsed initially.
Note: You can make any table collapsible, not just navboxes. Simply add <code>class="collapsible"</code>.
=== Code ===
<pre>
{| class="navbox collapsible collapsed" width="100%"
! class="infoboxheader" colspan="2" align="left" | Heading
|-
| Content goes here
|}
</pre>
== Creating sortable tables ==
=== Example ===
{| class="messagebox sortable"
! Name !! Address !! ZIP code
|-
| John Doe || 1239 Figueroa Ave || 1234hx
|-
| Bill Example || 260 Park Ave || 1234HX
|-
| Jane Doe || 148 13th St. || 123456
|}
*Note that:
**The tables sort alphabetically, not numerically. This might cause unexpected results when you sort by Address in this example.
**Numbers are sorted above letters. Captial letters are sorted the same as their lowercase equivalents. Sort by the ZIP Code field in this example to see for yourself.
**In the same fashion, the Name field will by sorted by first name, not by last name. If you want to sort by last names, make a separate field for last names.
**Any table can be made sortable just by adding <code>sortable</code> to the <code>class=</code> list.
=== Code ===
<pre>
{| class="messagebox sortable"
! Name !! Address !! ZIP code
|-
| John Doe || 1239 Figueroa Ave || 1234hx
|-
| Bill Example || 260 Park Ave || 1234HX
|-
| Jane Doe || 148 13th St. || 123456
|}
|}
</pre>
</pre>

To edit this page, please enter the words that appear below in the box (more info):

Refresh
Cancel Editing help (opens in new window)

  [] · [[]] · [[|]] · {{}} · · “” ‘’ «» ‹› „“ ‚‘ · ~ | ° &nbsp; · ± × ÷ ² ³ ½ · §
     [[Category:]] · [[:File:]] · [[Special:MyLanguage/]] · <code></code> · <nowiki></nowiki> <code><nowiki></nowiki></code> · <syntaxhighlight></syntaxhighlight> · <includeonly></includeonly> · <noinclude></noinclude> · #REDIRECT[[]] · <translate></translate> · <languages/> · {{#translation:}} · <tvar|></> · {{DEFAULTSORT:}} · <categorytree></categorytree> · <div style="clear:both;"></div> <s></s>


Your changes will be visible immediately.
  • For testing, please use the sandbox instead.
  • On talk pages, please sign your comment by typing four tildes (~~~~).