Difference between revisions of "Template:Infobox"

From Culture.si
(Reverted edits by Jurij (talk) to last revision by XOT)
Tag: Rollback
(Moving infobox to divs)
Line 80: Line 80:
 
</pre></noinclude>{{#ifeq:{{#this:depth}}|1|
 
</pre></noinclude>{{#ifeq:{{#this:depth}}|1|
 
<div class="contact-info">
 
<div class="contact-info">
<div class="contact-info-title">Contact <small class="track-link">{{#if:{{ISADMIN}}|[[Track:{{PAGENAME}}|Track]]|}}</small></div><table class="infobox">
+
<div class="contact-info-title">Contact <small class="track-link">{{#if:{{ISADMIN}}|[[Track:{{PAGENAME}}|Track]]|}}</small></div>
 +
<div class="infobox">
 +
<div class="img">
 
{{infoboxImageRow
 
{{infoboxImageRow
| label  =
+
| label  =
| name    = image-
+
| name    = image-
| value  = {{{image|}}}
+
| value  = {{{image|}}}
| type    = image
+
| type    = image
| hasimage = [[category:HAS IMAGE]]
+
| hasimage = [[category:HAS IMAGE]]
| noimage = {{missing image}}[[category:NO IMAGE]]
+
| noimage = {{missing image}}[[category:NO IMAGE]]
}}{{infoboxImageRow
+
}}
| label  =
+
{{infoboxImageRow
| name    = logo  
+
| label  =
| value  = {{{logo|{{{localname|{{{local name|{{{name|{{FULLPAGENAME}}}}}}}}}}} (logo).svg}}}
+
| name    = logo  
| type    = image
+
| value  = {{{logo|{{{localname|{{{local name|{{{name|{{FULLPAGENAME}}}}}}}}}}} (logo).svg}}}
| hasimage = [[category:HAS LOGO]]
+
| type    = image
| noimage = {{missing logo}}[[category:NO LOGO]]
+
| hasimage = [[category:HAS LOGO]]
}}{{Contact
+
| noimage = {{missing logo}}[[category:NO LOGO]]
| name      = {{#if:{{{localname|{{{local name|{{{name}}}}}}}}}|{{{localname|{{{local name|{{{name}}}}}}}}}|{{{name|{{FULLPAGENAME}}}}}}}
+
}}
| street    = {{{street|{{{street address|}}}}}}
+
</div>
| town      = {{{town|}}}
+
<div class="text">
| website  = {{{website|}}}
+
{{Contact
| email    = {{{email|}}}
+
| name      = {{#if:{{{localname|{{{local name|{{{name}}}}}}}}}|{{{localname|{{{local name|{{{name}}}}}}}}}|{{{name|{{FULLPAGENAME}}}}}}}
| email 2    = {{{email 2|}}}
+
| street    = {{{street|{{{street address|}}}}}}
| telephone = {{{telephone|}}}
+
| town      = {{{town|}}}
| fax      = {{{fax|}}}
+
| website  = {{{website|}}}
| save      = TRUE
+
| email    = {{{email|}}}
 +
| email 2    = {{{email 2|}}}
 +
| telephone = {{{telephone|}}}
 +
| fax      = {{{fax|}}}
 +
| save      = TRUE
 
}}{{#set:localname={{#if:{{{localname|{{{local name|{{{name}}}}}}}}}|{{{localname|{{{local name|{{{name}}}}}}}}}|{{{name|{{FULLPAGENAME}}}}}}}}}{{#if:{{{town|}}}
 
}}{{#set:localname={{#if:{{{localname|{{{local name|{{{name}}}}}}}}}|{{{localname|{{{local name|{{{name}}}}}}}}}|{{{name|{{FULLPAGENAME}}}}}}}}}{{#if:{{{town|}}}
 
| {{{
 
| {{{
Line 113: Line 119:
 
     {{#ifeq:{{#str:substr|{{{zip}}}|0|2}}|SI|
 
     {{#ifeq:{{#str:substr|{{{zip}}}|0|2}}|SI|
 
       {{infoboxRow
 
       {{infoboxRow
      | label = Region
+
      | label = Region
      | name  = Region
+
      | name  = Region
      | value = {{{region|{{#str:substr|{{{town|}}}|0|4}}}}}
+
      | value = {{{region|{{#str:substr|{{{town|}}}|0|4}}}}}
      | type  = text
+
      | type  = text
 
       }}
 
       }}
     }}{{infoboxRow
+
     }}
    | hidden = TRUE
+
    {{infoboxRow
    | label = Zip
+
    | hidden = TRUE
    | name  = Zip
+
    | label = Zip
    | value = {{{zip}}}
+
    | name  = Zip
    | type  = hidden
+
    | value = {{{zip}}}
     }}{{infoboxRow
+
    | type  = hidden
    | hidden = TRUE
+
     }}
    | label = TownName
+
    {{infoboxRow
    | name  = TownName
+
    | hidden = TRUE
    | value = {{{townName}}}
+
    | label = TownName
    | type  = hidden
+
    | name  = TownName
 +
    | value = {{{townName}}}
 +
    | type  = hidden
 
     }}
 
     }}
 
   }}
 
   }}
}}{{infoboxRow
+
}}
| label = Post
+
{{infoboxRow
| hidden = TRUE
+
| label = Post
| name  = Post
+
| hidden = TRUE
| value = {{{town|}}}
+
| name  = Post
| type  = text
+
| value = {{{town|}}}
}}{{infoboxRow
+
| type  = text
| label = Country
+
}}
| hidden = {{#if:{{{country|}}}||HIDDEN}}
+
{{infoboxRow
| name  = Country
+
| label = Country
| value = {{uc:{{{country|si}}}}}
+
| hidden = {{#if:{{{country|}}}||HIDDEN}}
| type  = text
+
| name  = Country
}}{{infoboxRow
+
| value = {{uc:{{{country|si}}}}}
| label = Proprietor
+
| type  = text
| name  = Proprietor
+
}}
| value = {{{proprietor|}}}
+
{{infoboxRow
| type  = link
+
| label = Proprietor
}}{{infoboxRow
+
| name  = Proprietor
| label = Founded by
+
| value = {{{proprietor|}}}
| name  = Founded by
+
| type  = link
| value = {{{founded by|}}}
+
}}
| type  = link
+
{{infoboxRow
}}{{infoboxRow
+
| label = Founded by
| label = &nbsp;
+
| name  = Founded by
| name  = Founded by
+
| value = {{{founded by|}}}
| value = {{{founded by 2|}}}
+
| type  = link
| type  = link
+
}}
}}{{infoboxRow
+
{{infoboxRow
| label = &nbsp;
+
| label = &nbsp;
| name  = Founded by
+
| name  = Founded by
| value = {{{founded by 3|}}}
+
| value = {{{founded by 2|}}}
| type  = link
+
| type  = link
}}{{infoboxRow
+
}}
| label = &nbsp;
+
{{infoboxRow
| name  = Founded by
+
| label = &nbsp;
| value = {{{founded by 4|}}}
+
| name  = Founded by
| type  = link
+
| value = {{{founded by 3|}}}
}}{{infoboxRow
+
| type  = link
| label = Managed by
+
}}
| name  = Managed by
+
{{infoboxRow
| value = {{{managed by|}}}
+
| label = &nbsp;
| type  = link
+
| name  = Founded by
}}{{infoboxRow
+
| value = {{{founded by 4|}}}
| label = &nbsp;
+
| type  = link
| name  = Managed by
+
}}
| value = {{{managed by 2|}}}
+
{{infoboxRow
| type  = link
+
| label = Managed by
}}{{infoboxRow
+
| name  = Managed by
| label = &nbsp;
+
| value = {{{managed by|}}}
| name  = Managed by
+
| type  = link
| value = {{{managed by 3|}}}
+
}}
| type  = link
+
{{infoboxRow
}}{{infoboxRow
+
| label = &nbsp;
| label = Organised by
+
| name  = Managed by
| name  = Organised by
+
| value = {{{managed by 2|}}}
| value = {{{organised by|{{{organized by|}}}}}}
+
| type  = link
| type  = link
+
}}
}}{{infoboxRow
+
{{infoboxRow
| label = &nbsp;
+
| label = &nbsp;
| name  = Organised by
+
| name  = Managed by
| value = {{{organised by 2|{{{organized by 2|}}}}}}
+
| value = {{{managed by 3|}}}
| type  = link
+
| type  = link
}}{{infoboxRow
+
}}
| label = &nbsp;
+
{{infoboxRow
| name  = Organised by
+
| label = Organised by
| value = {{{organised by 3|{{{organized by 3|}}}}}}
+
| name  = Organised by
| type  = link
+
| value = {{{organised by|{{{organized by|}}}}}}
}}{{infoboxRow
+
| type  = link
| label = Published by
+
}}
| name  = Published by
+
{{infoboxRow
| value = {{{published by|}}}
+
| label = &nbsp;
| type  = link
+
| name  = Organised by
}}{{infoboxRow
+
| value = {{{organised by 2|{{{organized by 2|}}}}}}
| label = &nbsp;
+
| type  = link
| name  = Published by
+
}}
| value = {{{published by 2|}}}
+
{{infoboxRow
| type  = link
+
| label = &nbsp;
}}{{infoboxRow
+
| name  = Organised by
| label = &nbsp;
+
| value = {{{organised by 3|{{{organized by 3|}}}}}}
| name  = Published by
+
| type  = link
| value = {{{published by 3|}}}
+
}}
| type  = link
+
{{infoboxRow
 +
| label = Published by
 +
| name  = Published by
 +
| value = {{{published by|}}}
 +
| type  = link
 +
}}
 +
{{infoboxRow
 +
| label = &nbsp;
 +
| name  = Published by
 +
| value = {{{published by 2|}}}
 +
| type  = link
 +
}}
 +
{{infoboxRow
 +
| label = &nbsp;
 +
| name  = Published by
 +
| value = {{{published by 3|}}}
 +
| type  = link
 
}}<!--{{infoboxRow
 
}}<!--{{infoboxRow
 
| label = Open
 
| label = Open
Line 224: Line 248:
 
| value = {{{official hours|}}}
 
| value = {{{official hours|}}}
 
| type  = text
 
| type  = text
}}-->{{infoboxRow
+
}}-->
| label = Frequency
+
{{infoboxRow
| name  = Frequency
+
| label = Frequency
| value = {{{frequency|}}}
+
| name  = Frequency
| type  = text
+
| value = {{{frequency|}}}
}}{{infoboxRow
+
| type  = text
| hidden = TRUE
+
}}
| label = Dates and duration
+
{{infoboxRow
| name  = Dates and duration
+
| hidden = TRUE
| value = {{{dates and duration|}}}
+
| label = Dates and duration
| type  = text
+
| name  = Dates and duration
}}{{#if:{{{duration weeks|}}}|{{DurationWeeks|weeks={{{duration weeks}}}}}}}{{infoboxRow
+
| value = {{{dates and duration|}}}
| label = Weeks
+
| type  = text
| hidden = TRUE
+
}}
| name  = Duration weeks
+
{{#if:{{{duration weeks|}}}|{{DurationWeeks|weeks={{{duration weeks}}}}}}}
| value = {{{duration weeks|}}}
+
{{infoboxRow
| type  = text
+
| label = Weeks
}}{{#if:{{{festival dates|}}}|{{FestivalDates|{{{festival dates}}}}}}}{{infoboxRow
+
| hidden = TRUE
| label = Festival dates
+
| name  = Duration weeks
| name  = Festival dates
+
| value = {{{duration weeks|}}}
| value = {{{festival dates|}}}
+
| type  = text
| type  = split
+
}}
}}{{infoboxRow
+
{{#if:{{{festival dates|}}}|{{FestivalDates|{{{festival dates}}}}}}}
| label = Location
+
{{infoboxRow
| name  = Location
+
| label = Festival dates
| value = {{{location|}}}
+
| name  = Festival dates
| type  = link
+
| value = {{{festival dates|}}}
}}{{{contacts|}}}
+
| type  = split
 +
}}
 +
{{infoboxRow
 +
| label = Location
 +
| name  = Location
 +
| value = {{{location|}}}
 +
| type  = link
 +
}}
 +
{{{contacts|}}}
 
{{#if:{{{accounts|}}}|
 
{{#if:{{{accounts|}}}|
<tr class="contact-separator"><td colspan="2"></td></tr>
+
<div>Online accounts:</div>
<tr><td colspan="2"><b>Online accounts:</b></td></tr>
+
{{#arr:dataloop
<tr><td colspan="2">{{#arr:dataloop
+
|{{#arr:match|{{{accounts}}}
|{{#arr:match|{{{accounts}}}
+
|https?:\/\/(.*?\.)?(.*?)\..*?\/(.*)}}
|https?:\/\/(.*?\.)?(.*?)\..*?\/(.*)}}
+
|each = {{infoboxRow
|each = {{infoboxRow
+
  |name= {{{2}}} account
  |name= {{{2}}} account
+
  |value = {{{0}}}
  |value = {{{0}}}
+
  |hidden = true
  |hidden = true
+
  |type = text
  |type = text
+
}}
 +
[{{{0}}} {{{2}}}]&nbsp;&nbsp;
 +
}}
 
}}
 
}}
[{{{0}}} {{{2}}}]&nbsp;&nbsp;
+
<div class="map">
}}</td></tr>
+
{{infoboxRow
}}{{infoboxRow
 
 
   | name  = Map
 
   | name  = Map
 
   | value = {{{map|}}}
 
   | value = {{{map|}}}
 
   | type  = embed
 
   | type  = embed
}}</table>
+
}}
 +
</div>
 +
 
 
{{{extra|}}}
 
{{{extra|}}}
 
{{EUProjectsForThisPage}}
 
{{EUProjectsForThisPage}}

Revision as of 23:41, 16 February 2021

Prekopiraj spodnjo strukturo v izvorno kodo članka. Pri Image vpiši samo ime slike.

{{Infobox
| name               =
| local name         =
| logo               = 
| image              = 
| street             = 
| town               = 
| region             = ''if not in Slovenia'' 
| country            = ''if not in Slovenia''
| website            = 
| email              = 
| telephone          = 
| fax                = 
| founded by         =
| founded by 2       =
| founded by 3       =
| founded by 4       =
| organised by       =
| organised by 2     =
| organised by 3     =
| managed by         = 
| managed by 2       = 
| managed by 3       = 
| published by       =
| published by 2     = 
| published by 3     =
| opening hours      =
| official hours     =
| frequency          = for festivals
| dates and duration = for festivals
| duration weeks     = for festivals
| festival dates     = d.m.YY - d.m.YY, for festivals
| contacts     = {{Contact
  | name        = 
  | role        =
  | street      = 
  | town        = 
  | website     = 
  | email       = 
  | email 2     = 
  | telephone   = 
  | fax         = 
  }}{{Contact
  | name        = 
  | role        =
  | street      = 
  | town        = 
  | website     = 
  | email       = 
  | telephone   = 
  | fax         = 
  }}{{Contact
  | name        = 
  | role        =
  | street      = 
  | town        = 
  | website     = 
  | email       = 
  | telephone   = 
  | fax         = 
  }}
| accounts = 
http://www.twitter.com/twid
http://www.facebook.com/fbid
http://www.youtube.com/ytid
http://www.vimeo.com/vimid
http://www.flickr.com/flid
http://www.soundcloud.com/scid
http://bandcamp.com/bcid
http://www.discogs.com/dgid
http://www.myspace.com/msid
http://www.reverbnation.com/rvid
http://www.last.fm/lfmid
http://www.behance.net/bhid
...

}}