cvs: presentations / time-ac2005.xml /slides/i18nl10n future.xml /slides/php5intro/nl p5pp.png p5pp.xml /slides/time basic-parse-time-new.xml
basic-using-zones.xml date-format.xml date-modify.xml date-timezone.xml default-timezone.xml improvements-overview.xml
problems-string-representation.xml problems-timezone-abbr.xml resources.xml timezone-object-1.xml timezone-object-2.xml timezone-utilities-1.xml
timezone-utilities-2.xml

From: Date: Fri, 22 Jul 2005 08:47:31 +0000
Subject: cvs: presentations / time-ac2005.xml /slides/i18nl10n future.xml /slides/php5intro/nl p5pp.png p5pp.xml /slides/time basic-parse-time-new.xml
basic-using-zones.xml date-format.xml date-modify.xml date-timezone.xml default-timezone.xml improvements-overview.xml
problems-string-representation.xml problems-timezone-abbr.xml resources.xml timezone-object-1.xml timezone-object-2.xml timezone-utilities-1.xml
timezone-utilities-2.xml
Groups: php.pres 
Request: Send a blank email to pres+get-1168@lists.php.net to get a copy of this message
derick Fri Jul 22 04:47:31 2005 EDT Added files: /presentations/slides/php5intro/nl p5pp.png /presentations/slides/time date-format.xml date-modify.xml date-timezone.xml default-timezone.xml resources.xml timezone-object-1.xml timezone-object-2.xml timezone-utilities-1.xml timezone-utilities-2.xml Modified files: /presentations time-ac2005.xml /presentations/slides/i18nl10n future.xml /presentations/slides/php5intro/nl p5pp.xml /presentations/slides/time basic-parse-time-new.xml basic-using-zones.xml improvements-overview.xml problems-string-representation.xml problems-timezone-abbr.xml Log: - Update ApacheCon talks.

http://cvs.php.net/diff.php/presentations/time-ac2005.xml?r1=1.1&r2=1.2&ty=u Index: presentations/time-ac2005.xml diff -u presentations/time-ac2005.xml:1.1 presentations/time-ac2005.xml:1.2 --- presentations/time-ac2005.xml:1.1 Mon Jun 6 08:59:47 2005 +++ presentations/time-ac2005.xml Fri Jul 22 04:47:25 2005 @@ -40,13 +40,19 @@ <!-- PHP - CODE EXAMPLES --> <slide>slides/time/basic-parse-time.xml</slide> <slide>slides/time/basic-parse-time-new.xml</slide> -<slide>slides/time/basic-using-zones.xml</slide> -<slide>slides/time/basic-other-mods.xml</slide> -<slide>slides/time/class-date.xml</slide> -<slide>slides/time/class-zone.xml</slide> +<!-- DATE EXAMPLES --> +<slide>slides/time/date-format.xml</slide> +<slide>slides/time/date-modify.xml</slide> +<slide>slides/time/basic-using-zones.xml</slide> +<slide>slides/time/default-timezone.xml</slide> +<slide>slides/time/timezone-object-1.xml</slide> +<slide>slides/time/timezone-object-2.xml</slide> +<slide>slides/time/date-timezone.xml</slide> <!-- set/get --> +<slide>slides/time/timezone-utilities-1.xml</slide> +<slide>slides/time/timezone-utilities-2.xml</slide> <!-- EXIT --> <slide>slides/php5intro/nl/p5pp.xml</slide> <!-- PHP and locales --> -<slide>slides/i18nl10n/resources.xml</slide> <!-- resources --> +<slide>slides/time/resources.xml</slide> <!-- resources --> </presentation> http://cvs.php.net/diff.php/presentations/slides/i18nl10n/future.xml?r1=1.1&r2=1.2&ty=u Index: presentations/slides/i18nl10n/future.xml diff -u presentations/slides/i18nl10n/future.xml:1.1 presentations/slides/i18nl10n/future.xml:1.2 --- presentations/slides/i18nl10n/future.xml:1.1 Wed Apr 27 09:11:38 2005 +++ presentations/slides/i18nl10n/future.xml Fri Jul 22 04:47:29 2005 @@ -3,7 +3,7 @@ <title>Future</title> <list> - <bullet>PHP 5.2 will support full Unicode based on ICU (IBMs Components for Unicode)</bullet> + <bullet>PHP 5.5 / 6 will support full Unicode based on ICU (IBMs Components for Unicode)</bullet> <bullet>ICU has functions for character sets, conversion, collation and localization (and more)</bullet> <bullet>Transliteration build on top of ICU features</bullet> </list> http://cvs.php.net/diff.php/presentations/slides/php5intro/nl/p5pp.xml?r1=1.2&r2=1.3&ty=u Index: presentations/slides/php5intro/nl/p5pp.xml diff -u presentations/slides/php5intro/nl/p5pp.xml:1.2 presentations/slides/php5intro/nl/p5pp.xml:1.3 --- presentations/slides/php5intro/nl/p5pp.xml:1.2 Tue May 10 18:34:03 2005 +++ presentations/slides/php5intro/nl/p5pp.xml Fri Jul 22 04:47:29 2005 @@ -2,7 +2,7 @@ <slide fontsize="6em"> <title>PHP 5 Power Programming</title> - <image filename='p5pp.jpg' align="center" pdf-scale="0.40"/> + <image filename='p5pp.png' align="center" pdf-scale="0.40"/> <list class="small"> <bullet>Written by Andi Gutmans, Stig Sæther Bakken and Derick Rethans</bullet> http://cvs.php.net/diff.php/presentations/slides/time/basic-parse-time-new.xml?r1=1.1&r2=1.2&ty=u Index: presentations/slides/time/basic-parse-time-new.xml diff -u presentations/slides/time/basic-parse-time-new.xml:1.1 presentations/slides/time/basic-parse-time-new.xml:1.2 --- presentations/slides/time/basic-parse-time-new.xml:1.1 Wed Jun 8 09:49:55 2005 +++ presentations/slides/time/basic-parse-time-new.xml Fri Jul 22 04:47:29 2005 @@ -2,23 +2,15 @@ <slide> <title>Parsing Dates - Take #2</title> - <blurb>Parsing strings for date time information with the ~strtotime()~ function:</blurb> + <blurb>Parsing strings for date time information with the ~date_create()~ function:</blurb> <example><![CDATA[<?php - $ts = Date::strtotime("2005-07-11 22:16:50 CEST"); + $ts = date_create("2005-07-11 22:16:50"); ?>]]></example> <break/> - <blurb>With initial timestamp:</blurb> - <example><![CDATA[<?php - $date = Date::strtotime("2005-07-11 22:16:50 CEST"); - $ts = Date::strtotime("next week", $date); -?>]]></example> -<break/> - - <blurb>The function calls are exactly the same, except that they will not - return an integer, but instead they return a Date object which is a wrapper - around a 64 bit integer (with some additional functionality - ofcourse).</blurb> + <blurb>This function will not return the timestamp as an integer, but + instead returns a Date object which is a wrapper around a 64 bit + integer (with some additional functionality ofcourse).</blurb> </slide> http://cvs.php.net/diff.php/presentations/slides/time/basic-using-zones.xml?r1=1.1&r2=1.2&ty=u Index: presentations/slides/time/basic-using-zones.xml diff -u presentations/slides/time/basic-using-zones.xml:1.1 presentations/slides/time/basic-using-zones.xml:1.2 --- presentations/slides/time/basic-using-zones.xml:1.1 Wed Jun 8 09:49:55 2005 +++ presentations/slides/time/basic-using-zones.xml Fri Jul 22 04:47:29 2005 @@ -4,20 +4,15 @@ <blurb>Specifying timezone abbreviation while parsing:</blurb> <example><![CDATA[<?php - $ts = Date::strtotime("1978-12-22 09:15 CET"); + $ts = date_create("1978-12-22 09:15 CET"); ?>]]></example> <break lines="3"/> - - <blurb>Specifying timezone identifier while parsing:</blurb> - <example><![CDATA[<?php - $ts = Date::strtotime("1978-12-22 09:15 Europe/Oslo"); -?>]]></example> + <blurb>Using timezone abbreviations is deprecated, one should always use + either a default timezone, or the full identifier.</blurb> <break lines="3"/> - <blurb>Setting a default timezone:</blurb> + <blurb>Specifying timezone identifier while parsing:</blurb> <example><![CDATA[<?php - Date::setDefaultTimezone("Europe/Oslo"); - $ts = Date::strtotime("1978-12-22 09:15"); + $ts = date_create("1978-12-22 09:15 Europe/Oslo"); ?>]]></example> </slide> - http://cvs.php.net/diff.php/presentations/slides/time/improvements-overview.xml?r1=1.1&r2=1.2&ty=u Index: presentations/slides/time/improvements-overview.xml diff -u presentations/slides/time/improvements-overview.xml:1.1 presentations/slides/time/improvements-overview.xml:1.2 --- presentations/slides/time/improvements-overview.xml:1.1 Wed Jun 8 09:49:55 2005 +++ presentations/slides/time/improvements-overview.xml Fri Jul 22 04:47:29 2005 @@ -4,10 +4,12 @@ <subtitle>Improvements</subtitle> <list> - <bullet>64 bit timestamps (more than Sun's life)</bullet> + <bullet>64 bit timestamps</bullet> <bullet>~strtotime()~ has been rewritten</bullet> <bullet>Nothing is Operating System dependent</bullet> <bullet>Full support for timezones, DST, date modifications</bullet> + <bullet>New format modifiers: %e% for timezone identifier and %o% for ISO Year</bullet> + <bullet>Advanced date handling functions</bullet> </list> </slide> http://cvs.php.net/diff.php/presentations/slides/time/problems-string-representation.xml?r1=1.1&r2=1.2&ty=u Index: presentations/slides/time/problems-string-representation.xml diff -u presentations/slides/time/problems-string-representation.xml:1.1 presentations/slides/time/problems-string-representation.xml:1.2 --- presentations/slides/time/problems-string-representation.xml:1.1 Wed Jun 8 09:49:55 2005 +++ presentations/slides/time/problems-string-representation.xml Fri Jul 22 04:47:29 2005 @@ -4,7 +4,7 @@ <subtitle>Date representation</subtitle> <blurb>Ambiguities:</blurb> - <example class="bit_larger">06 08 04</example> + <example class="bit_larger">06/08/04</example> <list> <bullet>August 6th, 2004</bullet> <bullet>June 8th, 2004</bullet> http://cvs.php.net/diff.php/presentations/slides/time/problems-timezone-abbr.xml?r1=1.1&r2=1.2&ty=u Index: presentations/slides/time/problems-timezone-abbr.xml diff -u presentations/slides/time/problems-timezone-abbr.xml:1.1 presentations/slides/time/problems-timezone-abbr.xml:1.2 --- presentations/slides/time/problems-timezone-abbr.xml:1.1 Wed Jun 8 09:49:55 2005 +++ presentations/slides/time/problems-timezone-abbr.xml Fri Jul 22 04:47:29 2005 @@ -5,8 +5,8 @@ <blurb>One identifier can mean different zones:</blurb> <list> - <bullet>PST: ~P~acific ~S~tandard ~T~ime, ~P~akistan ~S~tandard ~T~ime</bullet> - <bullet>EST: ~E~astern ~S~tandard ~T~ime (USA), ~E~astern ~S~tandard ~T~ime (Australia) and ~E~astern ~B~razil ~S~tandard ~T~ime</bullet> + <bullet>PST: *P*acific *S*tandard *T*ime, *P*akistan *S*tandard *T*ime</bullet> + <bullet>EST: *E*astern *S*tandard *T*ime (USA), *E*astern *S*tandard *T*ime (Australia) and *E*astern Brazil *S*tandard *T*ime</bullet> </list> <break lines="2"/> http://cvs.php.net/co.php/presentations/slides/time/date-format.xml?r=1.1&p=1 Index: presentations/slides/time/date-format.xml +++ presentations/slides/time/date-format.xml <?xml version="1.0" encoding="ISO-8859-1"?> <slide> <title>Formatting Dates</title> <blurb>Formatting using format specifiers:</blurb> <example result="1"><![CDATA[<?php date_default_timezone_set("Europe/Oslo"); $ts = date_create("1979-12-31 09:15"); echo date_format($ts, "D Y-m-d H:i:s - \I\S\O \W/\Y: W/o"), "<br/>\n";]]></example> <break/> <blurb>All format modifiers as supported by ~date()~ are supported too.</blurb> <break lines="2"/> <blurb>Predefined formats:</blurb> <example result="1"><![CDATA[<?php date_default_timezone_set("Europe/Oslo"); $ts = date_create("December 22nd, 2005 15:41"); echo date_format($ts, DATE_ISO8601), "<br/>\n"; echo date_format($ts, DATE_RFC1036), "<br/>\n"; echo date_format($ts, DATE_RSS), "<br/>\n";]]></example> </slide> http://cvs.php.net/co.php/presentations/slides/time/date-modify.xml?r=1.1&p=1 Index: presentations/slides/time/date-modify.xml +++ presentations/slides/time/date-modify.xml <?xml version="1.0" encoding="ISO-8859-1"?> <slide> <title>Modifying Dates</title> <blurb>Modifying dates and times:</blurb> <example result="1"><![CDATA[<?php date_default_timezone_set("Europe/Oslo"); $ts = date_create("now"); echo $ts->format(DATE_RFC2822), "<br/>\n"; echo $ts->modify("+2 days"); echo $ts->format(DATE_RFC2822), "<br/>\n"; echo $ts->modify("third month"); echo $ts->format(DATE_RFC2822), "<br/>\n"; echo $ts->modify("Friday +3 weeks"); echo $ts->format(DATE_RFC2822), "<br/>\n"; echo $ts->modify("next friday"); echo $ts->format(DATE_RFC2822), "<br/>\n"; ?>]]></example> </slide> http://cvs.php.net/co.php/presentations/slides/time/date-timezone.xml?r=1.1&p=1 Index: presentations/slides/time/date-timezone.xml +++ presentations/slides/time/date-timezone.xml <?xml version="1.0" encoding="ISO-8859-1"?> <slide> <title>Using Timezones</title> <subtitle>Changing timezones</subtitle> <blurb>Using the timezone when parsing a string with a date representation:</blurb> <example result="1"><![CDATA[<?php $tz1 = timezone_open("Pacific/Honolulu"); $tz2 = timezone_open("Europe/Amsterdam"); $tz3 = timezone_open("Australia/Melbourne"); $ts = date_create("1978-12-22 09:15", $tz1); echo $ts->getTimezone()->getName(), ': ', $ts->format(DATE_RFC822), "<br/>"; $ts->setTimezone($tz2); echo $ts->getTimezone()->getName(), ': ', $ts->format(DATE_RFC822), "<br/>"; date_timezone_set($ts, $tz3); echo timezone_name_get(date_timezone_get($ts)), ': ', date_format($ts, DATE_RFC822); ?>]]></example> <break lines="3"/> </slide> http://cvs.php.net/co.php/presentations/slides/time/default-timezone.xml?r=1.1&p=1 Index: presentations/slides/time/default-timezone.xml +++ presentations/slides/time/default-timezone.xml <?xml version="1.0" encoding="ISO-8859-1"?> <slide> <title>Default Timezones</title> <blurb>Setting a default timezone:</blurb> <example result="1"><![CDATA[<?php date_default_timezone_set("Europe/Oslo"); $ts = date_create("1978-12-22 09:15"); echo date_format($ts, "e"); ?>]]></example> <break lines="2"/> <blurb>Getting a default timezone:</blurb> <example result="0"><![CDATA[<?php $default_identifier = date_default_timezone_get(); echo $default_identifier; ?>]]></example> <break/> <blurb>Default timezone is 'guessed' in the following order:</blurb> <list> <bullet>~date_default_timezone_set()~ value</bullet> <bullet>%TZ% environment variable</bullet> <bullet>php.ini's %date.timezone% setting</bullet> <bullet>System's rendering of timezone abbreviation</bullet> </list> </slide> http://cvs.php.net/co.php/presentations/slides/time/resources.xml?r=1.1&p=1 Index: presentations/slides/time/resources.xml +++ presentations/slides/time/resources.xml <?xml version="1.0" encoding="ISO-8859-1"?> <slide fontsize="3.5em"> <title>Resources</title> <break lines="4"/> <link marginleft="0em" leader="This presentation: " href="http://derickrethans.nl/talks.php" target="_new"/> <link marginleft="0em" leader="World timezones: " href="http://www.worldtimezone.com/index24.php" target="_new"/> <link marginleft="0em" leader="Questions?: " href="dr@ez.no" target="_new"/> </slide> http://cvs.php.net/co.php/presentations/slides/time/timezone-object-1.xml?r=1.1&p=1 Index: presentations/slides/time/timezone-object-1.xml +++ presentations/slides/time/timezone-object-1.xml <?xml version="1.0" encoding="ISO-8859-1"?> <slide> <title>Using Timezones</title> <subtitle>The Timezone Object</subtitle> <blurb>Creating a timezone resource:</blurb> <example><![CDATA[<?php $tz = timezone_open("Asia/Singapore"); ?>]]></example> <break lines="3"/> <blurb>Using the timezone when parsing a string with a date representation:</blurb> <example><![CDATA[<?php $tz = timezone_open("Pacific/Honolulu"); $ts = date_create("1978-12-22 09:15", $tz); ?>]]></example> <break lines="3"/> <blurb>A passed timezone object does not override a *parsed* timezone:</blurb> <example><![CDATA[<?php $tz = timezone_open("Pacific/Honolulu"); $ts1 = date_create("1978-12-22 09:15 CET", $tz); $ts2 = date_create("1978-12-22 09:15 Europe/Amsterdam", $tz); ?>]]></example> </slide> http://cvs.php.net/co.php/presentations/slides/time/timezone-object-2.xml?r=1.1&p=1 Index: presentations/slides/time/timezone-object-2.xml +++ presentations/slides/time/timezone-object-2.xml <?xml version="1.0" encoding="ISO-8859-1"?> <slide> <title>Using Timezones</title> <subtitle>The Timezone Object</subtitle> <blurb>Getting a timezone's name:</blurb> <example result="1"><![CDATA[<?php $tz = timezone_open("Asia/Singapore"); echo timezone_name_get($tz), ', '; $tz = timezone_open("CEST"); echo $tz->getName(); ?>]]></example> <break lines="2"/> <blurb>Getting the current offset to GMT with a timezone for a specific date:</blurb> <example result="1"><![CDATA[<?php $tz = timezone_open("Europe/Amsterdam"); $d = date_create("2005-01-22 09:15"); echo timezone_offset_get($tz, $d), ', '; $d->modify("+6 months"); echo $tz->getOffset($d); ?>]]></example> </slide> http://cvs.php.net/co.php/presentations/slides/time/timezone-utilities-1.xml?r=1.1&p=1 Index: presentations/slides/time/timezone-utilities-1.xml +++ presentations/slides/time/timezone-utilities-1.xml <?xml version="1.0" encoding="ISO-8859-1"?> <slide> <title>Timezones Utilities</title> <subtitle>Transition Times</subtitle> <blurb>Creating a timezone resource:</blurb> <example result="1"><![CDATA[<?php $tz = timezone_open("Europe/Amsterdam"); $trs = timezone_transistions_get($tz); $trs = $tz->getTransistions(); echo "<pre>\n"; foreach ($trs as $tr) { printf("%20s %7d %d %s\n", $tr['time'], $tr['offset'], $tr['isdst'], $tr['abbr']); } ?>]]></example> </slide> http://cvs.php.net/co.php/presentations/slides/time/timezone-utilities-2.xml?r=1.1&p=1 Index: presentations/slides/time/timezone-utilities-2.xml +++ presentations/slides/time/timezone-utilities-2.xml <?xml version="1.0" encoding="ISO-8859-1"?> <slide> <title>Timezones Utilities</title> <subtitle>Abbreviations and Identifiers</subtitle> <blurb>All supported timezone idenfiers:</blurb> <example result="1"><![CDATA[<?php $ids = timezone_identifiers_list(); echo "Number of identifiers: ", count($ids), "<br/>"; echo implode(", ", array_slice($ids, 0, 5)), '...'; echo implode(", ", array_slice($ids, -5)); ?>]]></example> <break lines="2"/> <blurb>All supported timezone idenfiers:</blurb> <example result="1"><![CDATA[<?php $abbrs = timezone_abbreviations_list(); echo "<pre>\n"; foreach ($abbrs as $abbr => $id) { printf("%-4s %6d %d %s\n", strtoupper($abbr), $id['offset'], $id['dst'], $id['timezone_id']); } ?>]]></example> </slide>
« previous php.pres (#1168) next »