From Old School RuneScape Wiki
Jump to: navigation, search
Information icon-grey.svg
This is a documentation subpage for Template:Sitenotice.
It contains usage information, categories, and other content that is not part of the original template page.

This template is used on MediaWiki:Sitenotice


|type       = Type of site notice (all site notices of type are dismissed together regardless of notice number)
|image      = Displays an image before the text (should be set to x40px if it's too big).
|image bg   = Colour of the div where the image is displayed (Hex, Name or Class).
|text       = Text to be displayed 
|text bg    = Colour of the div where the text is displayed (Hex, Name or Class).
|text color = If for some reason you need the text to be a different colour (Hex, Name or Class).
  • The |type parameter may be omitted. All site notices of a given type are dismissed together regardless of the site notice id number. For example if a site notice of type oswf is dismissed, no other oswf type site messages will be displayed to the user (regardless of notice number).
  • The |image parameter may be omitted, leaving the text full width. |image bg will be automatically omitted with it.
  • Existing colour classes may be used on |text bg and |image bg instead, listed below. These will automatically switch between dark and ligth modes.
Backgrounds Text
table-bg-red text-red
table-bg-orange text-orange
table-bg-yellow text-yellow
table-bg-green text-green
table-bg-blue text-blue
table-bg-purple text-purple
table-bg-pink text-pink
table-bg-grey text-grey

Note that %CLOSE% is replaced by the close X, positioned absolutely in the top right of the parent (or left for ltr), however any padding/margins etc to ensure that the X does not overlap the contents must be added manually (done within this template).


Code Result
|image      = [[File:Ruby detail.png|x40px]]
|image bg   = #801c13
|text       = This is where you will write your text. You can use <code><choose></code> and such.
|text bg    = #9f261e
|text color = white
|text       = This is a text only sitenotice where the image was omitted, with changing background and text colors.
|text bg    = table-bg-green
|text color = text-green
|type       = oswf
|image      = [[File:Bond detail.png|40px|link=RS:OSWF]]
|image bg   = palegoldenrod
|text       = This is a sitenotice with a type, such as for oswf.
|text color = #fff
|text bg = #DAA520