Difference between revisions of "Template:RealmBox/Sandbox"
Jump to navigation
Jump to search
m |
m (Fixed minor bracket mistake; made FlagSize default to a non-rendered caption) |
||
(41 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
+ | <includeonly>{{#get_web_data:url=http://battlemaster.org/data/realm.php?World={{{World|{{{1}}}}}}&ID={{{RealmID|{{{2}}}}}}|format=XML | ||
+ | |data= | ||
+ | Island=continent, | ||
+ | TitleBackColor=colour, | ||
+ | Realm=name, | ||
+ | Capital=capital, | ||
+ | FullName=fullname, | ||
+ | Government=system, | ||
+ | Duchies=duchycount, | ||
+ | RulerTitle=rulertitle, | ||
+ | RulerName=rulername, | ||
+ | GeneralTitle=generaltitle, | ||
+ | GeneralName=generalname, | ||
+ | JudgeTitle=judgetitle, | ||
+ | JudgeName=judgename, | ||
+ | BankerTitle=bankertitle, | ||
+ | BankerName=bankername | ||
+ | Regions=regioncount, | ||
+ | Population=population, | ||
+ | Gold=gold, | ||
+ | Food=food, | ||
+ | Nobles=nobles, | ||
+ | }} | ||
{{RBTop}} | {{RBTop}} | ||
− | {{RBTitle|TextColor = {{{TitleTextColor| | + | {{RBTitle |
− | {{#if: {{{Flag|}}} | {{ | + | |TextColor = {{{TitleTextColor|{{{3|Black}}}}}} |
− | {{ | + | |BackColor = {{{TitleColor|{{{4|{{#external_value:TitleBackColor}}}}}}}} |
− | {{RBDouble | + | |Text = {{#external_value:FullName}} {{#if: {{{Flag|}}} | <br>[[File:{{{Flag}}}|{{{FlagSize|blank caption}}}]] {{#if: {{{FlagCaption|}}} | <br><div style="text-align: center; font-size: 75%; color: {{{TitleTextColor|Black}}}; font-weight:normal; font-style: oblique;">{{{FlagCaption}}}</div>|}}|}}<br><img src="http://battlemaster.org/experimental/RealmMap.php?shownames=regions&onlyRealm=yes&World={{{World|{{{1}}}}}}&Realm={{{RealmID|{{{2}}}}}}" height="{{{MapHeight|237}}}" width="{{{MapWidth|313}}}"> |}} |
− | + | {{RBTitle | |
− | {{# | + | |TextColor = {{{TitleTextColor|{{{3|Black}}}}}} |
− | {{#if: {{{StateReligion|}}} | | + | |BackColor = {{{TitleColor|{{{4|{{#external_value:TitleBackColor}}}}}}}} |
− | {{ | + | |Text = Overview}} |
− | + | {{RBDouble | |
− | {{ | + | |Left = |
− | + | <b>Island | |
− | {{RBDouble| | + | Capital |
− | {{# | + | <br>Government |
− | {{ | + | {{#if: {{{StateReligion|}}} | <br>State Religion<br>|}} |
− | {{ | + | Duchies |
− | + | <br>Regions | |
− | {{RBTitle |BackColor = {{{ | + | <br>Population |
− | {{RBSingle|CellAlign=center|Text = {{#ask: [[part of::{{ | + | <br>Gold |
+ | <br>Food | ||
+ | <br>Nobles</b> | ||
+ | |Right = | ||
+ | [[Located on::{{#external_value:Island}}]] | ||
+ | [[{{#external_value:Capital}}]] | ||
+ | <br>[[government type is::{{#external_value:Government}}]] | ||
+ | {{#if: {{{StateReligion|}}} | <br>[[has state religion::{{{StateReligion}}}]]<br>|}} | ||
+ | {{#external_value:Duchies}} | ||
+ | <br>{{#external_value:RegionCount}} | ||
+ | <br>{{#external_value:Population}} | ||
+ | <br>{{#external_value:Gold}} | ||
+ | <br>{{#external_value:Food}} | ||
+ | <br>{{#external_value:Nobles}}}} | ||
+ | {{RBTitle | ||
+ | |TextColor = {{{TitleTextColor|{{{3|Black}}}}}} | ||
+ | |BackColor = {{{TitleColor|{{{4|{{#external_value:TitleBackColor}}}}}}}} | ||
+ | |Text = Council}} | ||
+ | {{RBDouble | ||
+ | |BackColor = #CCCCCC | ||
+ | |LeftTextWeight = bold | ||
+ | |Left = {{#external_value:RulerTitle}} | ||
+ | |Right = [[has ruler::{{#external_value:RulerName}}| ]] {{FamilyLink|{{{World|{{{1}}}}}}|{{#external_value:RulerName}}}} }} | ||
+ | {{RBDouble | ||
+ | |LeftTextWeight = bold | ||
+ | |Left = | ||
+ | {{#external_value:GeneralTitle}} | ||
+ | {{#external_value:JudgeTitle}} | ||
+ | <br>{{#external_value:BankerTitle}} | ||
+ | |Right = {{FamilyLink|{{{World|{{{1}}}}}}|{{#external_value:GeneralName}}}} {{#set: has general::{{#external_value:GeneralName}}}} | ||
+ | {{FamilyLink|{{{World|{{{1}}}}}}|{{#external_value:JudgeName}}}} {{#set: has judge::{{#external_value:JudgeName}}}} | ||
+ | <br>{{FamilyLink|{{{World|{{{1}}}}}}|{{#external_value:BankerName}}}} {{#set: has banker::{{#external_value:BankerName}}}} | ||
+ | }} | ||
+ | {{RBTitle | ||
+ | |BackColor = {{{TitleColor|{{{4|{{#external_value:TitleBackColor}}}}}}}} | ||
+ | |TextColor = {{{TitleTextColor|{{{3|Black}}}}}} | ||
+ | |Text = Regions }} | ||
+ | {{RBSingle | ||
+ | |CellAlign=center | ||
+ | |BackColor=#DDDDDD | ||
+ | |Text = <table style="margin: 0px; border-collapse:collapse; width:95%; border: hidden;"><tr style="padding: 1px 0.5em; text-align: left; font-size: 100%; color: black; font-weight:normal; border-bottom: 1px solid #FFFFFF; background: #DDDDDD; width: 50%;"><td>'''Region'''</td><td>'''Lord'''</td></tr>{{#ask: [[part of::{{#external_value:Realm}}]] | mainlabel=region | ?has lord=Lord | format = template | template = RegionListFormat | headers = hide | default=Unknown}}</table>}} | ||
{{RBBottom}} | {{RBBottom}} | ||
+ | </includeonly> | ||
+ | |||
+ | <noinclude>{{DocSubpage}} | ||
+ | Complete revamp to use external data API. | ||
+ | |||
+ | <pre><nowiki>{{RealmBox|world|realmid|titletextcolor}}</nowiki></pre> | ||
+ | |||
+ | TitleTextColor is optional. Recommended if your realm color is really dark, or you won't be able to read the text on the title bars. | ||
+ | |||
+ | </noinclude> |
Latest revision as of 02:37, 19 February 2020
Page Information |
This is a documentation subpage for the RealmBox template. It contains usage information, categories and other content that is not part of the original template page. |
Complete revamp to use external data API.
{{RealmBox|world|realmid|titletextcolor}}
TitleTextColor is optional. Recommended if your realm color is really dark, or you won't be able to read the text on the title bars.