hcalendar-faq

(Difference between revisions)

Jump to: navigation, search
m (Q&A)
Current revision (23:45, 4 March 2008) (view source)
m (updated groups of events Q to reference hCalendar brainstorming to figure out)
 
(29 intermediate revisions not shown.)
Line 1: Line 1:
-
= hCalendar FAQ =
+
<h1> hCalendar FAQ </h1>
-
This page is for documenting Q&A about [[hcalendar|hCalendar]].  If you have a new question to ask, Please consider first asking your question on the [http://microformats.org/mailman/listinfo/microformats-discuss/ microformats-discuss] list.
+
This page is for documenting Q&A about [[hcalendar|hCalendar]].  If you have a new question to ask, Please consider first asking your question on the [irc://irc.freenode.net/#microformats microformats irc channel] (preferably) or the [http://microformats.org/mailman/listinfo/microformats-discuss/ microformats-discuss] list. New questions and answers should be added to the end of the list.  If you have a new question but not an answer, please add it to [[hcalendar-issues|hCalendar issues]].
-
== Q&A ==
+
<h2>Editing this Page</h2>
 +
Please do not use "?" or other punctuation in the headers - it helps to keep the URLs to their fragment identifiers shorter and easier to read, copy/paste etc.  See [[how-to-play]] for more wiki editing guidelines.
-
# ''How do I use a class inside <span class="vcalendar"> when I don't want the element I use it on to be a property of the calendar?''
+
== date and time ==
-
#*Use a class name that isn't a defined iCalendar property name.
+
=== Why does my event end a day earlier than I want ===
-
# ''What happens if the class is used both inside and outside <span class="vcalendar">?''
+
''Why does my event end a day earlier than I want?''
-
#* That works fine.
+
* DTEND is not inclusive. If you want an event to end on January 2nd, then you will need to set DTEND to 2006-01-03, one day later. This is because the event will END the first second of the date provided, so if you specify 2006-01-02, then that says that the end of the event is at midnight between the 1st and 2nd.
-
# ''What do I do if I want to add styling to a group of calendar events, especially if the calendar contains dynamic content? ''
+
 
-
#* You can write style rules that incorporate both the context of said group (say it is in an ordered list with class name "group" for example) and the events, e.g.:<code>ol.group .vevent { /* insert common styling here */ } </code>
+
=== Can I use hyphens and colons in my ISODates ===
-
# ''What do you do if you don't want the calendar or card to be displayed?''
+
''Can I use YYYY-MM-DDThh:mm:ss dates or do I have to use the YYYYMMDDThhmmss format?''
-
#* If you don't want the calendar or card to be displayed, why are you publishing it on the Web?
+
* hCalendar specifies [http://en.wikipedia.org/wiki/ISO8601 ISO8601 datetime format], and both examples are valid, you can use with or without hyphens/colons/spaces. Note, however, that both the [http://www.w3.org/TR/NOTE-datetime w3C note] and RFC 3339 recommend the use of the former, extended (delimited) format.
-
# ''What if you don't want specific properties to show up?''
+
 
-
#* You can trivially use CSS to hide (or otherwise alter the display) of certain properties.  E.g. if you want to hide the "location" from all your VEVENTs you would write a rule like this: <code> .vevent .location { display:none } </code>. This won't, however, keep the properties from being read in the HTML source.
+
=== Do I have to specify detailed time and timezone information ===
-
# ''If we use <abbr> title for the ISODate, how do we specify a different tooltip?''
+
''Do I have to specify detailed time and timezone information?''
-
#* For reasons of metadata transparency and visibility, it is recommended that you DO NOT specify a different tooltip.  However, if in your particular content or application you must, you can do so with a nested span e.g. <code> <abbr title="20050221"><span title="tooltip text">Feb. 21st</span></abbr></code>
+
* Include as much information as necessary, minimally include YYYY-MM-DD
-
# ''Would the use of <acronym> for DTSTART be just as good as <abbr>?''
+
 
-
#* It could be, but there is no need. The <abbr> element is also preferred as it is better defined. The <acronym> element, and in particular, the term "acronym" means different things to different people, and thus we are not using it in [[hcalendar|hCalendar]].
+
=== Why do I have to use a T between the date and time ===
-
# ''What happens if a browser doesn't support <abbr>?''
+
''Why do I have to use a 'T' between the date and time in ISO Dates?''
-
#* Then the human readable contents inside the element are displayed, which is the desirable behavior.
+
* You can NOT use a white-space character, the 'T' is mandatory to separate the date from the time.
-
# ''How is [[hcalendar|hCalendar]] different from xCalendar, i.e. [http://www.ietf.org/internet-drafts/draft-hare-xcalendar-03.txt draft iCalendar XML guidelines submitted to the IETF]?''
+
 
-
#* hCalendar and xCalendar are actually very similar in that they are both based on iCalendar standard, RFC2445. However, xCalendar is a way of representing iCalendar files using non-standard XML element names and attributes.  This is inadequate and unwieldly for serving on web pages. xCalendar is still a separate, encapsulated document in the context of the web, that requires yet another namespace. Nobody would ever look at an xCalendar XML file in the context of their ordinary browsing, unless it's XSLTed into something else, e.g. hCalendar. On the other hand, [[hcalendar|hCalendar]] is easily embeddable into normal XHTML web pages, easily stylable with CSS, cleanly separates human presentable date information vs. machine parsable ISO-8601 dates, etc. With hCalendar, calendar and events content appears both to the human user *and* to hCalendar-aware machine implementations, parsers, indexers, etc., on *today's* web.
+
=== How are recurring events represented ===
-
# ''Can you provide more precise location data for an hCalendar event such at latitude and longitude?''
+
''How are recurring events represented?'' also asked as ''How do I represent a repeating event in hCalendar?''
-
#* Yes, it is possible, by overlaying an [[hcard|hCard]] with the location markup, e.g. using your lat long example (taking the values as given, someone feel free to fix these to be the real values). The code example(s) are presumed to be inside an element with a class name of "vevent".  See the [[hcalendar-location-hcard-example]] page for details.  For more discussions of location data, geographic data, and research into current and potential future formats, see the [[location-formats|location formats]] page.
+
* If you take a look at [http://microformats.org/wiki/hcalendar-examples#Example_3 Example 3], there is a proposed means using an <em>RRULE</em> property along with a <em>freq</em> sub-property. It's a start - more brainstorming at [http://microformats.org/wiki/hcalendar-brainstorming#Recurring_Events hcalendar-brainstorming].
-
# ''When transforming an hcalendar to an ics file, do I have to convert the time to UTC?''
+
 
-
#* Yes. The iCalendar format does not permit the time to be published with an offset. hCalendars can be published with offsets, because this promotes accuracy, as it can more easily be verified (timezone math is hard), but tools which transform hCalendar to iCalendar must transformat times to UTC.
+
=== How do you markup just the year ===
-
# ''How are recurring events represented?''
+
''How does one markup just the year as opposed to an entire date? e.g. to represent age, or discussing "the past year" ?
 +
* Depends on the context.  If by "the past year", you mean the past *calendar* year, then mark it up as January 1st through December 31st.  If you mean the past 365 days, then mark it up according to whatever date it is relative to.  Etc.
 +
 
 +
=== How do I markup a datetime with timezone ===
 +
''How do I mark-up a date-time with the proper timezone?''
 +
* There are two ways to do this. First, you can add your timezone offset to the end of your date-time like this: 2006-01-01T12:00:00-0600.  [[http://aa.usno.navy.mil/faq/docs/world_tzones.html See a world timezone offset map here]]. Also, be sure to adjust offset to account for [[http://en.wikipedia.org/wiki/Daylight_saving_time Daylight Saving Time]] for events within applicable dates and locations. The other option is to convert your date-time with a timezone into a UTC date-time. iCalendar requires that times be in UTC, but hCalendar also allows for encoding your date-times as proper ISO date-times with timezone offsets.
 +
 
 +
== location ==
 +
=== How do you provide better location data for an event than lat long ===
 +
''Can you provide more precise location data for an hCalendar event such as latitude and longitude?'' also asked as  ''What is the best way to represent a full address in the Location?''
 +
* Yes, it is possible, by overlaying an [[hcard|hCard]] with the location markup (see [[hcalendar-brainstorming#hCard_locations|the brainstorming on hCard locations]]), e.g. using your lat long example (taking the values as given, someone feel free to fix these to be the real values). The code example(s) are presumed to be inside an element with a class name of "vevent".  See the [[hcalendar-location-hcard-example]] page for details.  For more discussions of location data, geographic data, and research into current and potential future formats, see the [[location-formats|location formats]] page.
 +
 
 +
=== How do you represent the language of a location ===
 +
''How do you represent the language of a LOCATION?'' - AKA the language parameter.
 +
* Use the (X)HTML "lang" attribute.  See for example [[hcard-authoring#Set_the_lang_when_different|the explanation in hCard authoring of how to use "lang"]].
 +
 
 +
== markup details ==
 +
=== Why are the root class names vcalendar and vevent ===
 +
''Why are the root class names "vcalendar" and "vevent" and not "hcalendar"?''
 +
* [[hcalendar|hCalendar]] is based on the iCalendar spec (RFC 2445), which itself is based on vCalendar.  The names of objects have remained consistent throughout and are based on the original names from vCalendar.
 +
 
 +
=== Is there an example of hCalendar in a table ===
 +
''Is there an example of hCalendar in a table?''
 +
* Take a look at: [[hcalendar-examples-in-wild#conference_schedules|hCalendar examples in the wild: conference schedules]].
 +
 
 +
=== Would acronym for dtstart be just as good as abbr ===
 +
''Would the use of &lt;acronym&gt; for DTSTART be just as good as &lt;abbr&gt;?''
 +
* It could be, but there is no need.  The &lt;abbr&gt;  element is also preferred as it is better defined.  The &lt;acronym&gt; element, and in particular, the term "acronym" means different things to different people, and thus we are not using it in [[hcalendar|hCalendar]].
 +
 
 +
=== What if a browser lacks support for abbr ===
 +
''What happens if a browser doesn't support &lt;abbr&gt;?''
 +
* Then the human readable contents inside the element are displayed, which is the desirable behavior.
 +
 
 +
== styling and display ==
 +
=== How do I add styling to a group of events ===
 +
''What do I do if I want to add styling to a group of calendar events, especially if the calendar contains dynamic content? ''
 +
* You can write style rules that incorporate both the context of said group (say it is in an ordered list with class name "group" for example) and the events, e.g.:<code>ol.group .vevent { /* insert common styling here */ } </code>
 +
 
 +
=== What if you do not want the calendar to be displayed ===
 +
''What do you do if you don't want the calendar or card to be displayed?''
 +
* If you don't want the calendar or card to be displayed, why are you publishing it on the Web?
 +
 
 +
=== What if you do not want some properties to show up ===
 +
''What if you don't want specific properties to show up?''
 +
* Though not recommended, you can trivially use CSS to hide (or otherwise alter the display) of certain properties.  E.g. if you want to hide the "location" from all your VEVENTs you would write a rule like this: <code> .vevent .location { display:none } </code>. This won't, however, keep the properties from being read in the HTML source; or seen by people who don't have CSS enabled; or discovered by search engines or other robots. Remember: invisible (meta)data is bad.
 +
 
 +
=== How do you specify a tooltip on a datetime ===
 +
''If we use &lt;abbr&gt; title for the ISODate, how do we specify a different tooltip?''
 +
* For reasons of metadata transparency and visibility, it is recommended that you DO NOT specify a different tooltip.  However, if in your particular content or application you must, you can do so with a nested span e.g. <code> <abbr title="20050221"><span title="tooltip text">Feb. 21st</span></abbr></code>
 +
 
 +
== interactions with other class names ==
 +
=== How do I use a class name inside an hCalendar event without it becoming a property ===
 +
''How do I use a class inside <span class="vcalendar"> when I don't want the element I use it on to be a property of the calendar?''
 +
*Use a class name that isn't a defined iCalendar property name.
 +
 
 +
=== What happens if a class name is used both inside and outside an hCalendar ===
 +
''What happens if the class is used both inside and outside <span class="vcalendar">?''
 +
* That works fine.
 +
 
 +
== tools ==
 +
=== What programs or services convert iCalendar to hCalendar ===
 +
''Are there any programs of services that convert from iCalendar to hCalender?''
 +
*At the moment there are no plans to create a program. There are several issues when converting, mainly HOW the information is represented in HTML. Since you can use just about any element which could the converter choose. This is not to say a converter shouldn't be built, but it is out of the scope of microformats.
 +
 
 +
=== Why does Outlook not import my ics file ===
 +
''Why won't Outlook import my ics file''
 +
* Outlook is picky about some properties. With some versions of Outlook, UID, DTSTAMP and METHOD are mandatory. Be sure you have marked-up your hCalendar with a class="uid" and a class="dtstamp" in a class="vevent".  See [[icalendar-implementations]] for more details and quirks of particular iCalendar implementations.
 +
 
 +
=== When transforming hCalendar to ics should datetimes be converted to UTC ===
 +
''When transforming an hCalendar to a .ics file, do I have to convert the time to UTC?''
 +
* Yes. The iCalendar format does not permit the time to be published with an offset. hCalendars can be published with offsets, because this promotes accuracy, as it can more easily be verified (timezone math is hard), but tools which transform hCalendar to iCalendar must transformat times to UTC.
 +
 
 +
== other calendar formats ==
 +
=== How is hCalendar different from xCalendar ===
 +
''How is [[hcalendar|hCalendar]] different from xCalendar, i.e. iCalendar XML guidelines submitted as an [http://www.ietf.org/ID.html IETF Internet-Draft]?''
 +
* hCalendar and xCalendar are actually very similar in that they are both based on iCalendar standard, RFC2445. However, xCalendar is a way of representing iCalendar files using non-standard XML element names and attributes.  This is inadequate and unwieldly for serving on web pages. xCalendar is still a separate, encapsulated document in the context of the web, that requires yet another namespace. Nobody would ever look at an xCalendar XML file in the context of their ordinary browsing, unless it's XSLTed into something else, e.g. hCalendar. On the other hand, [[hcalendar|hCalendar]] is easily embeddable into normal XHTML web pages, easily stylable with CSS, cleanly separates human presentable date information vs. machine parsable ISO-8601 dates, etc. With hCalendar, calendar and events content appears both to the human user *and* to hCalendar-aware machine implementations, parsers, indexers, etc., on *today's* web.
 +
 
 +
== not supported currently ==
 +
=== Is it possible to represent groups of events ===
 +
''Is it possible to represent groups of events?'' - e.g workshops at a conference.
 +
* Not at this time. iCalendar does have such a mechanism: the RELATED-TO property with a RELTYPE attribute of PARENT/CHILD/SIBLING (parent being the default). However, this feature of iCalendar is not currently specified in hCalendar.  See [[hcalendar-brainstorming#grouping_events|hCalendar brainstorming: grouping events]].
 +
 
 +
== Related Pages ==
 +
{{hcalendar-related-pages}}

Current revision

Contents

hCalendar FAQ

This page is for documenting Q&A about hCalendar. If you have a new question to ask, Please consider first asking your question on the microformats irc channel (preferably) or the microformats-discuss list. New questions and answers should be added to the end of the list. If you have a new question but not an answer, please add it to hCalendar issues.

Editing this Page

Please do not use "?" or other punctuation in the headers - it helps to keep the URLs to their fragment identifiers shorter and easier to read, copy/paste etc. See how-to-play for more wiki editing guidelines.

date and time

Why does my event end a day earlier than I want

Why does my event end a day earlier than I want?

Can I use hyphens and colons in my ISODates

Can I use YYYY-MM-DDThh:mm:ss dates or do I have to use the YYYYMMDDThhmmss format?

Do I have to specify detailed time and timezone information

Do I have to specify detailed time and timezone information?

Why do I have to use a T between the date and time

Why do I have to use a 'T' between the date and time in ISO Dates?

How are recurring events represented

How are recurring events represented? also asked as How do I represent a repeating event in hCalendar?

How do you markup just the year

How does one markup just the year as opposed to an entire date? e.g. to represent age, or discussing "the past year" ?

How do I markup a datetime with timezone

How do I mark-up a date-time with the proper timezone?

location

How do you provide better location data for an event than lat long

Can you provide more precise location data for an hCalendar event such as latitude and longitude? also asked as What is the best way to represent a full address in the Location?

How do you represent the language of a location

How do you represent the language of a LOCATION? - AKA the language parameter.

markup details

Why are the root class names vcalendar and vevent

Why are the root class names "vcalendar" and "vevent" and not "hcalendar"?

Is there an example of hCalendar in a table

Is there an example of hCalendar in a table?

Would acronym for dtstart be just as good as abbr

Would the use of <acronym> for DTSTART be just as good as <abbr>?

What if a browser lacks support for abbr

What happens if a browser doesn't support <abbr>?

styling and display

How do I add styling to a group of events

What do I do if I want to add styling to a group of calendar events, especially if the calendar contains dynamic content?

What if you do not want the calendar to be displayed

What do you do if you don't want the calendar or card to be displayed?

What if you do not want some properties to show up

What if you don't want specific properties to show up?

How do you specify a tooltip on a datetime

If we use <abbr> title for the ISODate, how do we specify a different tooltip?

interactions with other class names

How do I use a class name inside an hCalendar event without it becoming a property

How do I use a class inside when I don't want the element I use it on to be a property of the calendar?

What happens if a class name is used both inside and outside an hCalendar

What happens if the class is used both inside and outside ?

tools

What programs or services convert iCalendar to hCalendar

Are there any programs of services that convert from iCalendar to hCalender?

Why does Outlook not import my ics file

Why won't Outlook import my ics file

When transforming hCalendar to ics should datetimes be converted to UTC

When transforming an hCalendar to a .ics file, do I have to convert the time to UTC?

other calendar formats

How is hCalendar different from xCalendar

How is hCalendar different from xCalendar, i.e. iCalendar XML guidelines submitted as an IETF Internet-Draft?

not supported currently

Is it possible to represent groups of events

Is it possible to represent groups of events? - e.g workshops at a conference.

Related Pages

This specification is a work in progress. As additional aspects are discussed, understood, and written, they will be added. These thoughts, issues, and questions are kept in separate pages.

hcalendar-faq was last modified: Tuesday, March 4th, 2008

Views