Template:Event
From syn2cat - HackerSpace.lu
(Difference between revisions)
m (test 2) |
|||
Line 1: | Line 1: | ||
− | <includeonly>{{#ifexpr: {{#time: U | {{{ | + | <includeonly><!-- |
− | '''Note:''' this article is about a passed event. | + | --> {{#ifexpr:{{#time: U | {{{EndDate|}}} }}<{{#time: U }}|<div style="border: 2px solid #007A20; padding: 0.5em 1em 0.3em 0.5em; color: #007A20;"> |
− | </div> | }} | + | '''Note:''' this article is about a passed event.</div>|}}<!-- |
− | {| class="" cellpadding="2" cellspacing="0" <!-- | + | --> {| class="" cellpadding="2" cellspacing="0" <!-- |
--> style="float: right; width: 300px; margin: 0 0 1em 1em; border: 2px solid #AAAAAA; background-color: #FFFFFF" | --> style="float: right; width: 300px; margin: 0 0 1em 1em; border: 2px solid #AAAAAA; background-color: #FFFFFF" | ||
|+ '''[[Form:Event|Add your Event]]''' | |+ '''[[Form:Event|Add your Event]]''' | ||
Line 17: | Line 17: | ||
| #default = [[Image:Event.png|link=|left|40px]] | | #default = [[Image:Event.png|link=|left|40px]] | ||
}}<!-- | }}<!-- | ||
− | --><span style="font-size: 150%;">{{#if:{{{what|}}}| {{{what}}} | {{PAGENAME}} }}</span> | + | --><span style="font-size: 150%;">{{#if:{{{what|}}}|{{{what}}}|{{PAGENAME}} }}</span> |
|- | |- | ||
| colspan="2" style="padding: 7px;" | [[Description::{{{intro|}}}]] | | colspan="2" style="padding: 7px;" | [[Description::{{{intro|}}}]] | ||
|- | |- | ||
− | | colspan="2" style="padding: 10px 0px; text-align:center;" |<!-- setting custom image if available-->[[Image:{{#if: {{{logo|}}} |<!--then-->{{{logo}}}|<!--else-->G8033.png}}| | + | | colspan="2" style="padding: 10px 0px; text-align:center;" |<!-- setting custom image if available-->[[Image:{{#if: {{{logo|}}} |<!--then-->{{{logo}}}|<!--else-->G8033.png}}|200px|link=]] |
|- | |- | ||
| style="padding: 0 7px;" | '''[[Template:Event#EventType|Type of Event]]''': || [[Is Event of Type::{{{eventtype}}}]] | | style="padding: 0 7px;" | '''[[Template:Event#EventType|Type of Event]]''': || [[Is Event of Type::{{{eventtype}}}]] | ||
Line 28: | Line 28: | ||
|- | |- | ||
| style="padding: 0 7px;" | '''[[Template:Event#Till|Till]]''': || {{#if: {{{till|}}} | [[EndDate::{{{till}}}]] | [[EndDate::{{{from}}}]] }} | | style="padding: 0 7px;" | '''[[Template:Event#Till|Till]]''': || {{#if: {{{till|}}} | [[EndDate::{{{till}}}]] | [[EndDate::{{{from}}}]] }} | ||
− | |||
− | |||
|- | |- | ||
| style="padding: 0 7px;" | '''[[Template:Event#Recurring|Recurring]]''': || [[Is Recurring::{{{recurring|}}}]] | | style="padding: 0 7px;" | '''[[Template:Event#Recurring|Recurring]]''': || [[Is Recurring::{{{recurring|}}}]] | ||
Line 45: | Line 43: | ||
| colspan="2" style="padding: 0.5em; color: white; background-color: #AAAAAA" | <span style="font-size: 120%;">Location</span> | | colspan="2" style="padding: 0.5em; color: white; background-color: #AAAAAA" | <span style="font-size: 120%;">Location</span> | ||
|- | |- | ||
− | | style="padding: 0 7px;" | '''[[Template:Event#Where|Where]]''': || [[Has location::{{{location|}}}]] ({{Address|{{#show: {{{location|}}} | ?Has address|link=none}}|{{#show: {{{location|}}} | ?Has city}}|{{#show: {{{location|}}} | ?Has country}} | + | | style="padding: 0 7px;" | '''[[Template:Event#Where|Where]]''': || [[Has location::{{{location|}}}]] ({{Address|{{#show: {{{location|}}} | ?Has address|link=none}}|{{#show: {{{location|}}} | ?Has city}}|{{#show: {{{location|}}} | ?Has country}}}}) |
|- | |- | ||
| style="vertical-align:top; padding: 0 7px;" | '''[[Template:Event#Map|Map]]''': | | style="vertical-align:top; padding: 0 7px;" | '''[[Template:Event#Map|Map]]''': | ||
| | | | ||
{{#display_point: | {{#display_point: | ||
− | {{#show: {{{location|}}} | ?Has | + | {{#show: {{{location|}}} | ?Has address}} {{#show: {{{location|}}} | ?Has city}}~{{Address|{{#show: {{{location|}}} | ?Has address}}|{{#show: {{{location|}}} | ?Has city}}|{{#show: {{{location|}}} | ?Has country}}}} |
|width=250 | |width=250 | ||
|height=250 | |height=250 | ||
+ | |service=googlemaps | ||
|controls=small | |controls=small | ||
}} | }} | ||
− | |||
− | |||
− | |||
− | |||
|} | |} | ||
<!-- *** Let's automate the semantic info *** --> | <!-- *** Let's automate the semantic info *** --> | ||
− | {{# | + | <!-- Get coordinates in here --> |
+ | [[Has coordinates::{{#show: {{{location|}}} | ?Has coordinates|link=none}}| ]] | ||
<!-- Switch Categories on eventtype --> | <!-- Switch Categories on eventtype --> | ||
{{#switch: {{{eventtype}}} | {{#switch: {{{eventtype}}} | ||
Line 72: | Line 68: | ||
| #default = [[Category:Event]] | | #default = [[Category:Event]] | ||
}} | }} | ||
− | <!-- End Switch Category | + | <!-- End Switch Category --> |
− | + | [[Is U19::{{{u19}}}| ]] | |
+ | {{#ifeq: {{{u19|}}} | yes | [[Category:U19]] }} | ||
<!-- Only use the dates function on non-recurring events --> | <!-- Only use the dates function on non-recurring events --> | ||
{{#ifeq: {{{recurring}}} | no | {{#arraymap: {{#dates: | StartDate={{{from}}} | EndDate={{{till}}} }}|,|x|[[Has date::x| ]]| }} }} | {{#ifeq: {{{recurring}}} | no | {{#arraymap: {{#dates: | StartDate={{{from}}} | EndDate={{{till}}} }}|,|x|[[Has date::x| ]]| }} }} |
Revision as of 17:54, 22 October 2010
Usage
Copy and paste this code or simply use the Form:Event to add your event.
If you don't set a "till" date, the "from" date will be used.
{{Event | logo = <filename> | eventtype = <party, conference, camp, workshop, meeting> | what = <event title> | intro= <event description> | from= <Datetime> | till= <Datetime> | recurring = <no, daily, weekly, bi-weekly, monthly, xofmonth, bi-monthly, yearly> | cost=0€ | u19 = <yes/no> | location=Hackerspace, Strassen | contact= <comma-delimited list of the organisers> | attendees = <string> Everyone | url=http://www.website.com }}