cvs: presentations / php6-unicode-ffm2006.xml xdebug-brasil6.xml /slides/ezc example-persistentobject-databaseschema-tiein.xml
imageconversion-structure.xml mail-structure.xml questions.xml template-custom.xml template-syntax1.xml template-syntax2.xml /slides/ezc/workshop
assignment-base-repository.xml assignment-base-repository2.xml assignment-base-repository3.xml assignment-base-repository4.xml
assignment-base-repository5.xml assignment-base-repository6.xml assignment-base.xml assignment-configuration.xml assignment-eventlog.xml
assignment-graph.xml assignment-imageconversion.xml assignment-mail1.xml assignment-persistent-object1.xml assignment-template1.xml
assignment-template2.xml assignment-template3.xml configuration.xml database.xml eventlog.xml graph.xml installing.xml introduction.xml mail-image.xml
program.xml template.xml /slides/time improvements-overview.xml /slides/toolbox goals-library.xml /slides/xdebug dr_mail_test.php
ezc_mail_setup.php how-to! -install.xml infinite.png request-vars.png stacktrace3b.png var_dump.png which-code-do-i-use.xml xdebug-var-dump.xml
| From: | Derick Rethans | Date: | Wed, 29 Nov 2006 20:22:58 +0000 |
| Subject: | cvs: presentations / php6-unicode-ffm2006.xml xdebug-brasil6.xml /slides/ezc example-persistentobject-databaseschema-tiein.xml imageconversion-structure.xml mail-structure.xml questions.xml template-custom.xml template-syntax1.xml template-syntax2.xml /slides/ezc/workshop assignment-base-repository.xml assignment-base-repository2.xml assignment-base-repository3.xml assignment-base-repository4.xml assignment-base-repository5.xml assignment-base-repository6.xml assignment-base.xml assignment-configuration.xml assignment-eventlog.xml assignment-graph.xml assignment-imageconversion.xml assignment-mail1.xml assignment-persistent-object1.xml assignment-template1.xml assignment-template2.xml assignment-template3.xml configuration.xml database.xml eventlog.xml graph.xml installing.xml introduction.xml mail-image.xml program.xml template.xml /slides/time improvements-overview.xml /slides/toolbox goals-library.xml /slides/xdebug dr_mail_test.php ezc_mail_setup.php how-to! -install.xml infinite.png request-vars.png stacktrace3b.png var_dump.png which-code-do-i-use.xml xdebug-var-dump.xml |
||
| Groups: | php.pres | ||
| Request: | Send a blank email to pres+get-1369@lists.php.net to get a copy of this message | ||
derick Wed Nov 29 20:22:58 2006 UTC
Added files:
/presentations php6-unicode-ffm2006.xml xdebug-brasil6.xml
/presentations/slides/ezc
example-persistentobject-databaseschema-tiein.xml
imageconversion-structure.xml
mail-structure.xml template-custom.xml
template-syntax1.xml template-syntax2.xml
/presentations/slides/ezc/workshop assignment-base-repository.xml
assignment-base-repository2.xml
assignment-base-repository3.xml
assignment-base-repository4.xml
assignment-base-repository5.xml
assignment-base-repository6.xml
assignment-base.xml
assignment-configuration.xml
assignment-eventlog.xml
assignment-graph.xml
assignment-imageconversion.xml
assignment-mail1.xml
assignment-persistent-object1.xml
assignment-template1.xml
assignment-template2.xml
assignment-template3.xml
configuration.xml database.xml
eventlog.xml graph.xml
installing.xml introduction.xml
mail-image.xml program.xml
template.xml
Modified files:
/presentations/slides/ezc questions.xml
/presentations/slides/time improvements-overview.xml
/presentations/slides/toolbox goals-library.xml
/presentations/slides/xdebug dr_mail_test.php ezc_mail_setup.php
how-to-install.xml infinite.png
request-vars.png stacktrace3b.png
var_dump.png which-code-do-i-use.xml
xdebug-var-dump.xml
Log:
- Frankfurt and Brasil talks.
http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/questions.xml?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/ezc/questions.xml diff -u presentations/slides/ezc/questions.xml:1.3 presentations/slides/ezc/questions.xml:1.4 --- presentations/slides/ezc/questions.xml:1.3 Mon Jun 19 07:09:40 2006 +++ presentations/slides/ezc/questions.xml Wed Nov 29 20:22:58 2006 @@ -7,10 +7,10 @@ <blurb>Resources:</blurb> <list> - <bullet>*Download*: http://ez.no/download/ez_components</bullet> + <bullet>*Download*: http://ez.no/ezcomponents/download</bullet> <bullet>*Documentation*: http://ez.no/doc/components/overview</bullet> <bullet>*Mailinglist*: http://lists.ez.no/mailman/listinfo/components</bullet> - <bullet>*Forum*: http://ez.no/community/forum/ez_components</bullet> + <bullet>*IRC*: #ezcomponents @ Freenode</bullet> <bullet>*These Slides*: :-:url:-:</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/time/improvements-overview.xml?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/time/improvements-overview.xml diff -u presentations/slides/time/improvements-overview.xml:1.3 presentations/slides/time/improvements-overview.xml:1.4 --- presentations/slides/time/improvements-overview.xml:1.3 Thu Nov 2 12:22:22 2006 +++ presentations/slides/time/improvements-overview.xml Wed Nov 29 20:22:58 2006 @@ -4,7 +4,10 @@ <subtitle>Improvements</subtitle> <list> - <bullet>64 bit timestamps</bullet> + <bullet>"Using a (signed) 64-bit value introduces a new wraparound date + in about 290 billion years, on Sunday, December 4, 292,277,026,596. + However, this problem is not widely regarded as a pressing + issue."</bullet> <bullet>~strtotime()~ has been rewritten</bullet> <bullet>Nothing is Operating System dependent</bullet> <bullet>Full support for timezones, DST, date modifications</bullet> http://cvs.php.net/viewvc.cgi/presentations/slides/toolbox/goals-library.xml?r1=1.6&r2=1.7&diff_format=u Index: presentations/slides/toolbox/goals-library.xml diff -u presentations/slides/toolbox/goals-library.xml:1.6 presentations/slides/toolbox/goals-library.xml:1.7 --- presentations/slides/toolbox/goals-library.xml:1.6 Thu Sep 14 19:51:56 2006 +++ presentations/slides/toolbox/goals-library.xml Wed Nov 29 20:22:58 2006 @@ -4,6 +4,7 @@ <list> <bullet>Provide a solid platform for PHP application development</bullet> + <bullet>Don't force a structure: no "framework"</bullet> <bullet>Clean and simple API</bullet> <bullet>Excellent documentation</bullet> <bullet>Keep backward compatibility for longer periods of time</bullet> http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/dr_mail_test.php?r1=1.1&r2=1.2&diff_format=u Index: presentations/slides/xdebug/dr_mail_test.php diff -u presentations/slides/xdebug/dr_mail_test.php:1.1 presentations/slides/xdebug/dr_mail_test.php:1.2 --- presentations/slides/xdebug/dr_mail_test.php:1.1 Thu Mar 30 17:07:16 2006 +++ presentations/slides/xdebug/dr_mail_test.php Wed Nov 29 20:22:58 2006 @@ -4,7 +4,7 @@ error_reporting(E_ALL); $parser = new ezcMailParser(); -$set = new ezcSingleFileSet( dirname(__FILE__).'/ezcmailtest.mail' ); +$set = new ezcMailFileSet( array( dirname(__FILE__).'/ezcmailtest.mail' ) ); echo "Memory: ", xdebug_memory_usage(), " bytes\n\n"; $mail = $parser->parseMail( $set ); http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/ezc_mail_setup.php?r1=1.1&r2=1.2&diff_format=u Index: presentations/slides/xdebug/ezc_mail_setup.php diff -u presentations/slides/xdebug/ezc_mail_setup.php:1.1 presentations/slides/xdebug/ezc_mail_setup.php:1.2 --- presentations/slides/xdebug/ezc_mail_setup.php:1.1 Thu Mar 30 17:07:16 2006 +++ presentations/slides/xdebug/ezc_mail_setup.php Wed Nov 29 20:22:58 2006 @@ -137,43 +137,5 @@ } -class ezcSingleFileSet implements ezcMailParserSet -{ - private $fp = null; - - public function __construct( $file ) - { - $fp = fopen( $file, 'r' ); - if( $fp == false ) - { - throw new Exception( "Could not open file $file for testing." ); - } - $this->fp = $fp; - } - - public function getNextLine() - { - if( feof( $this->fp ) ) - { - if( $this->fp != null ) - { - fclose( $this->fp ); - $this->fp = null; - } - return null; - } - $next = rtrim( fgets( $this->fp ), "\r\n" ); - if( $next == "" && feof( $this->fp ) ) // eat last linebreak - { - return null; - } - return $next; - } - - public function nextMail() - { - return false; - } -} ?> http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/how-to-install.xml?r1=1.1&r2=1.2&diff_format=u Index: presentations/slides/xdebug/how-to-install.xml diff -u presentations/slides/xdebug/how-to-install.xml:1.1 presentations/slides/xdebug/how-to-install.xml:1.2 --- presentations/slides/xdebug/how-to-install.xml:1.1 Thu Mar 30 17:07:16 2006 +++ presentations/slides/xdebug/how-to-install.xml Wed Nov 29 20:22:58 2006 @@ -9,9 +9,9 @@ <blurb>Without PEAR:</blurb> <list class="numbered"> - <bullet>wget http://xdebug.org/files/xdebug-2.0.0beta5.tgz</bullet> - <bullet>tar -xvzf xdebug-2.0.0beta5.tgz</bullet> - <bullet>cd xdebug-2.0.0beta5</bullet> + <bullet>wget http://xdebug.org/files/xdebug-2.0.0RC1.tgz</bullet> + <bullet>tar -xvzf xdebug-2.0.0RC1.tgz</bullet> + <bullet>cd xdebug-2.0.0RC1</bullet> <bullet>phpize</bullet> <bullet>./configure</bullet> <bullet>make</bullet> http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/infinite.png?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/xdebug/infinite.png http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/request-vars.png?r1=1.1&r2=1.2&diff_format=u Index: presentations/slides/xdebug/request-vars.png http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/stacktrace3b.png?r1=1.1&r2=1.2&diff_format=u Index: presentations/slides/xdebug/stacktrace3b.png http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/var_dump.png?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/xdebug/var_dump.png http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/which-code-do-i-use.xml?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/xdebug/which-code-do-i-use.xml diff -u presentations/slides/xdebug/which-code-do-i-use.xml:1.3 presentations/slides/xdebug/which-code-do-i-use.xml:1.4 --- presentations/slides/xdebug/which-code-do-i-use.xml:1.3 Wed Jun 28 10:02:58 2006 +++ presentations/slides/xdebug/which-code-do-i-use.xml Wed Nov 29 20:22:58 2006 @@ -11,5 +11,5 @@ xdebug_get_code_coverage(); xdebug_stop_code_coverate();</example> <break/> - <link target="new" href="http://kossu/coverage/index.htm">demo</link> + <link target="new" href="http://kossu/coverage/index.html">demo</link> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/xdebug-var-dump.xml?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/xdebug/xdebug-var-dump.xml diff -u presentations/slides/xdebug/xdebug-var-dump.xml:1.3 presentations/slides/xdebug/xdebug-var-dump.xml:1.4 --- presentations/slides/xdebug/xdebug-var-dump.xml:1.3 Wed Jun 28 10:02:58 2006 +++ presentations/slides/xdebug/xdebug-var-dump.xml Wed Nov 29 20:22:58 2006 @@ -4,8 +4,12 @@ <image filename="var_dump.png" align="center" pdf-scale="0.7"/> <break lines="2"/> - <blurb>%&lt;?php%</blurb> - <blurb>%xdebug_var_dump(); // or just var_dump()%</blurb> - <blurb>%?>%</blurb> + <example><![CDATA[<?php +ini_set( 'xdebug.var_display_max_data', 25 ); +ini_set( 'xdebug.var_display_max_depth', 4 ); + +xdebug_var_dump(); // or just var_dump() +?>]]></example> +<break lines="2"/> </slide> http://cvs.php.net/viewvc.cgi/presentations/php6-unicode-ffm2006.xml?view=markup&rev=1.1 Index: presentations/php6-unicode-ffm2006.xml +++ presentations/php6-unicode-ffm2006.xml <?xml version="1.0" encoding="iso-8859-1"?> <presentation template="css" navmode="html" navbarbackground="#4373b4" navbartopiclinks="0" navColor="#f1fbff" logo1="" stylesheet="presentations/slides/perf/ezp.css" backgroundfixed="1" > <topic>Localization and Internationalization</topic> <title>PHP 6 and Unicode</title> <event>International PHP Conference</event> <location>Frankfurt, Germany</location> <date>November 7th, 2006</date> <speaker>Derick Rethans</speaker> <email>dr@ez.no</email> <url>http://derickrethans.nl/talks.php</url> <slide>slides/clustering/title.xml</slide> <!-- UNICODE --> <slide>slides/i18nl10n/what-languages.xml</slide> <!-- what is the problem actually? --> <slide>slides/i18nl10n/challenges2.xml</slide> <slide>slides/i18nl10n/sorting.xml</slide> <slide>slides/i18nl10n/convert.xml</slide> <slide>slides/i18nl10n/php-can-do-it-now.xml</slide> <slide>slides/i18nl10n/php-now-iconv.xml</slide> <slide>slides/i18nl10n/php-now-mbstring.xml</slide> <slide>slides/i18nl10n/php-now-locales.xml</slide> <!-- UNICODE --> <slide>slides/i18nl10n/unicode.xml</slide> <slide>slides/i18nl10n/composition.xml</slide> <slide>slides/i18nl10n/properties.xml</slide> <!-- PHP SOON --> <slide>slides/i18nl10n/goals-1.xml</slide> <slide>slides/i18nl10n/basics-1.xml</slide> <slide>slides/i18nl10n/surrogates.xml</slide> <!-- how does the encoding work? --> <slide>slides/i18nl10n/icu.xml</slide> <slide>slides/i18nl10n/roadmap.xml</slide> <slide>slides/i18nl10n/unicode-semantics.xml</slide> <!-- STRINGS --> <slide>slides/i18nl10n/string-types.xml</slide> <slide>slides/i18nl10n/string-literals.xml</slide> <slide>slides/i18nl10n/characters-not-bytes.xml</slide> <slide>slides/i18nl10n/upgrading-locale.xml</slide> <slide>slides/i18nl10n/locale-example.xml</slide> <slide>slides/i18nl10n/locale-example2.xml</slide> <slide>slides/i18nl10n/locale-example-arrays.xml</slide> <slide>slides/i18nl10n/iterator-example.xml</slide> <!-- DIFFERENT ENCODINGS --> <slide>slides/i18nl10n/encoding-overview.xml</slide> <slide>slides/i18nl10n/script-encoding.xml</slide> <slide>slides/i18nl10n/script-encoding-pragma.xml</slide> <slide>slides/i18nl10n/script-encoding-fun1.xml</slide> <slide>slides/i18nl10n/script-encoding-fun2.xml</slide> <slide>slides/i18nl10n/runtime-encoding.xml</slide> <slide>slides/i18nl10n/http-output-encoding.xml</slide> <slide>slides/i18nl10n/stream-encoding1.xml</slide> <slide>slides/i18nl10n/stream-encoding2.xml</slide> <slide>slides/i18nl10n/stream-encoding3.xml</slide> <slide>slides/i18nl10n/translit1.xml</slide> <slide>slides/i18nl10n/fallback-encoding.xml</slide> <!-- EXIT --> <slide>slides/i18nl10n/when.xml</slide> <slide>slides/i18nl10n/resources.xml</slide> <!-- resources --> </presentation> http://cvs.php.net/viewvc.cgi/presentations/xdebug-brasil6.xml?view=markup&rev=1.1 Index: presentations/xdebug-brasil6.xml +++ presentations/xdebug-brasil6.xml <?xml version="1.0" encoding="iso-8859-1"?> <presentation template="css" navmode="html" navbarbackground="#4373b4" navbartopiclinks="0" navColor="#f1fbff" logo1="" stylesheet="presentations/slides/perf/ezp.css" backgroundfixed="1" > <topic>Debugging</topic> <title>Xdebug</title> <event>PHP Conference Brasil</event> <location>São Paulo, Brasil</location> <date>Dec 2nd, 2006</date> <speaker>Derick Rethans</speaker> <email>dr@ez.no</email> <url>http://files.derickrethans.nl/xdebug-brasil6.pdf</url> <slide>slides/xdebug/title.xml</slide> <!-- INTRODUCTION --> <slide>slides/xdebug/why-debugger1.xml</slide> <slide>slides/xdebug/why-debugger2.xml</slide> <slide>slides/xdebug/why-debugger3.xml</slide> <slide>slides/xdebug/how-to-install.xml</slide> <slide>slides/xdebug/how-to-install2.xml</slide> <slide>slides/xdebug/how-to-install-win.xml</slide> <slide>slides/xdebug/how-to-install3.xml</slide> <slide>slides/xdebug/why-crash.xml</slide> <!-- max nesting, function trace --> <slide>slides/xdebug/where-error.xml</slide> <slide>slides/xdebug/debug-req-vars.xml</slide> <slide>slides/xdebug/xdebug-var-dump.xml</slide> <slide>slides/xdebug/how-many-functions.xml</slide> <slide>slides/xdebug/how-much-time.xml</slide> <slide>slides/xdebug/how-much-memory.xml</slide> <slide>slides/xdebug/wtf-happens.xml</slide> <slide>slides/xdebug/live-demo.xml</slide> <slide>slides/xdebug/which-code-do-i-use.xml</slide> <slide>slides/xdebug/profiling.xml</slide> <slide>slides/xdebug/profiling2.xml</slide> <slide>slides/xdebug/live-demo.xml</slide> <slide>slides/xdebug/analyse-running-script.xml</slide> <slide>slides/xdebug/live-demo.xml</slide> <slide>slides/xdebug/resources.xml</slide> </presentation> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/example-persistentobject-databaseschema-tiein.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/example-persistentobject-databaseschema-tiein.xml +++ presentations/slides/ezc/example-persistentobject-databaseschema-tiein.xml <?xml version="1.0" encoding="utf-8"?> <slide> <title>PersistentObjectDatabaseSchemaTiein</title> <blurb>Creating definition files from the database:</blurb> <break/> <example><![CDATA[php pear/ezc/PersistentObjectDatabaseSchemaTiein/rungenerator.php -f mysql -s mysql://root@localhost/workshop data/persistentobject-defs]]></example> <break lines="3"/> <blurb>Often the generated definition files should be changed, for example to change class names and/or column names.</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/imageconversion-structure.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/imageconversion-structure.xml +++ presentations/slides/ezc/imageconversion-structure.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>ImageConversion</title> <subtitle>Ideas</subtitle> <list> <bullet>Transformations can be applied to images</bullet> <bullet>Each transformation consists of one or more filters</bullet> </list> <break lines="2"/> <blurb>Available filters are:</blurb> <list> <bullet>*ezcImageColorspaceFilters*: colorspace</bullet> <bullet>*ezcImageGeometryFilters*: crop, scale, scaleExact, scaleHeight, scalePercent, scaleWidth</bullet> <bullet>*ezcImageWatermarkFilters*: watermarkAbsolute, watermarkPercent</bullet> <bullet>*ezcImageEffectFilters*: border, noise, swirl</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/mail-structure.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/mail-structure.xml +++ presentations/slides/ezc/mail-structure.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Mail</title> <subtitle>Parsed Mail Structure</subtitle> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/template-custom.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/template-custom.xml +++ presentations/slides/ezc/template-custom.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Template Syntax</title> <subtitle>Custom Functions</subtitle> <blurb>Allows you to extend the template language:</blurb><break/> <example><![CDATA[string_to_time( $message->logtime )]]></example> <break lines="2"/> <example><![CDATA[<?php class StringToTimeCall implements ezcTemplateCustomFunction { public static function getCustomFunctionDefinition( $name ) { if ( $name == "string_to_time" ) { $def = new ezcTemplateCustomFunctionDefinition(); $def->class = __CLASS__; $def->method = "strtotime"; $def->parameters = array("timestring"); return $def; } return false; } public static function strtotime( $string ) { return strtotime( $string ); } } $config = ezcTemplateConfiguration::getInstance(); $config->addExtension( 'StringToTimeCall' ); ?>]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/template-syntax1.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/template-syntax1.xml +++ presentations/slides/ezc/template-syntax1.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Template Syntax</title> <blurb>Variable declaration</blurb> <list type="number"> <bullet>%{use $parameter}%</bullet> <bullet>%{var $i, $j}%</bullet> </list> <break lines="2"/> <blurb>Assigments and expressions</blurb> <list> <bullet>Assignments: =, +=, -=, *=, >=, /=, %=</bullet> <bullet>Arithmetic operators: +, -, \*, /, %</bullet> <bullet>Comparison operators: ==, ===, !=, !==, <, >, <=, >=</bullet> <bullet>Logical operators: ||, &&, !</bullet> <bullet>increment, decrement: $v++, $v--, ++$v, --$v</bullet> <bullet>*Note:* Assignments cannot be used inside an expression: %{if $a = 2}%</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/template-syntax2.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/template-syntax2.xml +++ presentations/slides/ezc/template-syntax2.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Template Syntax</title> <subtitle>Extra features</subtitle> <blurb>Delimiter:</blurb><break/> <example><![CDATA[{foreach array("one", "two", "three") as $n} {$n}{delimiter}, {/delimiter} {/foreach}]]></example> <break lines="3"/> <blurb>Cycle:</blurb><break/> <example><![CDATA[{var $elements = 0..(10 + 2)} {cycle $color = array( "#FF0000", "#00FF00" )} <table> {foreach $elements as $el increment $color offset 3 limit 5} <tr style="background-color: {$color}"> <td>Number</td><td>{$el}</td> </tr> {/foreach} </table>]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository.xml +++ presentations/slides/ezc/workshop/assignment-base-repository.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Class Repository (1/3)</title> <subtitle>~15 minutes</subtitle> <blurb>In the directory "%~/include/persistent_classes%" create four files containing classes:</blurb> <list type="number"> <bullet>%category.php% containing the class %wpcCategory% with the attributes: |ff0000|$id| and |ff0000|$name|.</bullet> <bullet>%image.php% containing the class %wpcImage% with the attributes: |ff0000|$id|, |ff0000|$messageId|, |ff0000|$category_id|, |ff0000|$description|, |ff0000|$send_time|, |ff0000|$orig_x_size|, |ff0000|$orig_y_size|, |ff0000|$owner_email|, |ff0000|$owner_name| and |ff0000|$shutterspeed|.</bullet> <bullet>%image_file.php% containing the class %wpcImageFile% with the attributes: |ff0000|$id|, |ff0000|$image_id|, |ff0000|$type| and |ff0000|$data|.</bullet> <bullet>%log.php% containing the class %wpcLog% with the attributes: |ff0000|$id|, |ff0000|$logtime|, |ff0000|$src|, |ff0000|$category| and |ff0000|$message|.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository2.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository2.xml +++ presentations/slides/ezc/workshop/assignment-base-repository2.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Class Repository (2/3)</title> <subtitle>~15 minutes</subtitle> <blurb>Use the following template for classes:</blurb> <example><![CDATA[<?php class wpcImageFile { private $id = null; public $image_id = null; public $type = null; public $data = null; public function getState() { $result = array(); $result['id'] = $this->id; $result['image_id'] = $this->image_id; $result['type'] = $this->type; $result['data'] = $this->data; return $result; } public function setState( array $properties ) { foreach ( $properties as $key => $value ) { $this->$key = $value; } } } ?> ]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository3.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository3.xml +++ presentations/slides/ezc/workshop/assignment-base-repository3.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Class Repository (3/3)</title> <subtitle>~15 minutes</subtitle> <blurb>In the directory %~/include/persistent_classes/autoload%, create the following files:</blurb> <break lines="2"/> <blurb>category_autoload.php</blurb> <example><![CDATA[<?php return array( 'wpcCategory' => 'category.php', ); ?>]]></example> <break lines="2"/> <blurb>image_autoload.php</blurb> <example><![CDATA[<?php return array( 'wpcImage' => 'image.php', 'wpcImageFile' => 'image_file.php', ); ?>]]></example> <break lines="2"/> <blurb>log_autoload.php</blurb> <example><![CDATA[<?php return array( 'wpcLog' => 'log.php', ); ?>]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository4.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository4.xml +++ presentations/slides/ezc/workshop/assignment-base-repository4.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Persistent Object Definitions (1/3)</title> <subtitle>~15 minutes</subtitle> <blurb>Change the include/ezc-setup.php file to include:</blurb> <example><![CDATA[<?php ezcBase::addClassRepository( dirname( __FILE__ ) . '/persistent_classes', null, 'wpc' ); ?>]]></example> <break lines="3"/> <blurb>Create the persistent object definition files:</blurb> <example><![CDATA[php pear/ezc/PersistentObjectDatabaseSchemaTiein/rungenerator.php -f mysql -s mysql://root@localhost/workshop data/persistentobject-defs]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository5.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository5.xml +++ presentations/slides/ezc/workshop/assignment-base-repository5.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Persistent Object Definitions (2/3)</title> <subtitle>~15 minutes</subtitle> <blurb>Modify the generated files in %~/data/persistentobject-defs%:</blurb> <list type="number"> <bullet>Rename the files to %wpccategory.php%, %wpcimage.php%, %wpcimagefile.php% and %wpclog.php%.</bullet> <bullet>In the files, change %$def->class% to the correct classnames: %wpcImage%, %wpcImageFile%, %wpcCategory% and %wpcLog%.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository6.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository6.xml +++ presentations/slides/ezc/workshop/assignment-base-repository6.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Persistent Object Definitions (3/3)</title> <subtitle>~15 minutes</subtitle> <blurb>Add information about relations to the following files:</blurb> <break lines="2"/> <blurb>~/data/persistentobject-defs/wpccategory.php:</blurb> <example><![CDATA[<?php $def->relations['wpcImage'] = new ezcPersistentOneToManyRelation( "category", "image" ); $def->relations['wpcImage']->columnMap = array( new ezcPersistentSingleTableMap( 'id', 'category_id' ) ); ?>]]></example> <break lines="2"/> <blurb>~/data/persistentobject-defs/wpcimage.php:</blurb> <example><![CDATA[<?php $def->relations['wpcImageFile'] = new ezcPersistentOneToManyRelation( "image", "image_file" ); $def->relations['wpcImageFile']->columnMap = array( new ezcPersistentSingleTableMap( 'id', 'image_id' ) ); ?>]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base.xml +++ presentations/slides/ezc/workshop/assignment-base.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Installation</title> <subtitle>~10 minutes</subtitle> <blurb>Configure pear as follows:</blurb> <example type="shell"> pear config-set php_dir /home/ezc/pear pear config-set data_dir /home/ezc/pear-data pear config-set test_dir /home/ezc/pear-test pear config-set doc_dir /home/ezc/pear-doc pear config-set preferred_state alpha</example> <break lines="3"/> <blurb>Install the components with the PEAR installer.</blurb> <break lines="3"/> <blurb>Create the script "%~/include/ezc-setup.php%" that sets up the components' autoloading mechanism. Set the include path to "%/home/ezc/pear:/home/ezc:.%".</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-configuration.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-configuration.xml +++ presentations/slides/ezc/workshop/assignment-configuration.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Configuration</title> <subtitle>~15 minutes</subtitle> <list> <bullet>Create the file "watermark.ini" in %/home/ezc/data/configuration% with the following contents:</bullet> </list> <example>[size] max_width=900 max_height=600</example> <list> <bullet>Extend the %scripts/read-mail.php% script to use the configurable sizes for the watermarked image.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-eventlog.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-eventlog.xml +++ presentations/slides/ezc/workshop/assignment-eventlog.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: EventLog</title> <subtitle>~30 minutes</subtitle> <list> <bullet>Extend the image-details.php script to log how often an image has been viewed. Use the following writer definition:</bullet> </list> <example><![CDATA[<?php $db = ezcDbFactory::create( 'mysql://root@localhost/workshop' ); $writer = new ezcLogDatabaseWriter( $db, "log" ); $writer->source = 'src'; $writer->datetime = 'logtime'; $writer->imageid = 'imageid'; ?>]]></example> <list> <bullet>Make sure to log the imageid in a custom parameter to the logger.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-graph.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-graph.xml +++ presentations/slides/ezc/workshop/assignment-graph.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Graph</title> <subtitle>~30 minutes</subtitle> <list> <bullet>View the graph.php to see whether the logging works.</bullet> <bullet>And then start modifying the render options. Maybe there is a price for the best looking graph ;-)</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-imageconversion.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-imageconversion.xml +++ presentations/slides/ezc/workshop/assignment-imageconversion.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: ImageAnalysis & ImageConversion</title> <subtitle>~25 minutes</subtitle> <blurb>Enhance the shell script to extract the photo's shutterspeed with ImageAnalysis and print the results to standard output as well.</blurb> <break lines="3"/> <blurb>Enhance the script to generate three images from the original image. Those images should be generated to %/tmp%:</blurb> <list type="number"> <bullet>A greyscale thumbnail in the size of maximum 50x50: %small_thumb.jpg% (type 1)</bullet> <bullet>A thumbnail in the size of maximum 100x100: %large_thumb.jpg% (type 2)</bullet> <bullet>A resized version (800x600) but added on top a watermark (%logo.png%) in the top-left corner: %watermark.jpg% (type 3)</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-mail1.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-mail1.xml +++ presentations/slides/ezc/workshop/assignment-mail1.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Mail</title> <subtitle>~20 minutes</subtitle> <list> <bullet>Send a mail message with Thunderbird (Applications->Internet->Icedove Mail Client) to ezc@workshop.ez.no.local and attach a JPEG image (you can find them in /home/ezc/data/workshop-images).</bullet> <bullet>Press "Get Mail" to check if the mail has been sent correctly. The mail should also stay on the server.</bullet> <bullet>Write a small console PHP script "~/scripts/import-mail.php" that reads all mails in the mailbox and writes to standard output: sender name, sender email address, filename of the parser attachment, the body of the first text part and the message ID.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-persistent-object1.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-persistent-object1.xml +++ presentations/slides/ezc/workshop/assignment-persistent-object1.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: PersistentObject</title> <subtitle>~30 minutes</subtitle> <blurb>In the %~/scripts/read-mail.php% script create a function that uses the ezcPersistentSession:</blurb> <list type="number"> <bullet>Check if the category (the subject of the mail message) already exists, and store the ID of the category in a variable. (Hint: %$q = $session->createFindQuery();%</bullet> <bullet>If it does not exist, create the category and store the new ID in a variable. (Hint: %$session->save( $cat );%)</bullet> <bullet>Check if the mail/image already has been added to the database. (Hint: Use the messageId property of the wpcImage class)</bullet> <bullet>If the image does not exist, create a new one and store it in the database.</bullet> <bullet>Add the 4 related wpcImageFile objects. Use %$session->addRelatedObject();% to link them to the image object.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-template1.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-template1.xml +++ presentations/slides/ezc/workshop/assignment-template1.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Template (1/3)</title> <subtitle>Image overview: ~45 minutes</subtitle> <list> <bullet>Create a PHP script "%~/www/index.php%"</bullet> <bullet>Set-up the Template component's templatePath and compilePath to %/home/ezc/data/templates%.</bullet> <bullet>Retrieve all %wpcCategory% objects with ezcPersistentSession, and send the resulting array *and* the session itself to a template called "%index.ezt%".</bullet> <bullet>Create the template %~/data/templates/index.ezt% that lists all the categories as "h2" elements.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-template2.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-template2.xml +++ presentations/slides/ezc/workshop/assignment-template2.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Template (2/3)</title> <subtitle>Image overview: ~45 minutes</subtitle> <list> <bullet>Include the %include/template_function_call.php% file in the %index.php% script and use the %addExtension()% method of the ezcTemplateConfiguration to add it to the template system.</bullet> <bullet>In the template %index.ezt% use the following code to retrieve all related images for each category:</bullet> </list> <example>{foreach $categories as $category} <h2>{$category->name}</h2> {$categoryImages = call( $session, "getRelatedObjects", array( $category, "wpcImage" ))}</example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-template3.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-template3.xml +++ presentations/slides/ezc/workshop/assignment-template3.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Template (3/3)</title> <subtitle>Image overview: ~45 minutes</subtitle> <list> <bullet>Then loop over the %$categoryImages% and display them as:</bullet> </list> <example><![CDATA[<a href='image-details.php?id=42'> <img src='image.php?id=42&type=1'/> </a>]]></example> <list> <bullet>If everything is ready, check the result with Firefox.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/configuration.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/configuration.xml +++ presentations/slides/ezc/workshop/configuration.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Configuration</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/database.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/database.xml +++ presentations/slides/ezc/workshop/database.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Database</blurb> <blurb class="large_blurb_center">DatabaseSchema</blurb> <blurb class="large_blurb_center">PerisistentObject</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/eventlog.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/eventlog.xml +++ presentations/slides/ezc/workshop/eventlog.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">EventLog</blurb> <blurb class="large_blurb_center">EventLogDatabaseTiein</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/graph.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/graph.xml +++ presentations/slides/ezc/workshop/graph.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Graph</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/installing.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/installing.xml +++ presentations/slides/ezc/workshop/installing.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Installation</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/introduction.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/introduction.xml +++ presentations/slides/ezc/workshop/introduction.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Introduction</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/mail-image.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/mail-image.xml +++ presentations/slides/ezc/workshop/mail-image.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Mail</blurb> <blurb class="large_blurb_center">ImageConversion</blurb> <blurb class="large_blurb_center">ImageAnalysis</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/program.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/program.xml +++ presentations/slides/ezc/workshop/program.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <subtitle>Program</subtitle> <list> <bullet>Introduction (30 mins)</bullet> <bullet>Installing the components (15 mins)</bullet> <bullet>Mail, ImageConversion and ImageAnalysis (1 hour)</bullet> <bullet>Database, DatabaseSchema and PersistentObject (1 hour)</bullet> <bullet>Template (1 hour)</bullet> <bullet>Configuration (30 mins)</bullet> <bullet>EventLog (30 mins)</bullet> <bullet>Graph (1 hour)</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/template.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/template.xml +++ presentations/slides/ezc/workshop/template.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Template</blurb> </slide>
http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/questions.xml?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/ezc/questions.xml diff -u presentations/slides/ezc/questions.xml:1.3 presentations/slides/ezc/questions.xml:1.4 --- presentations/slides/ezc/questions.xml:1.3 Mon Jun 19 07:09:40 2006 +++ presentations/slides/ezc/questions.xml Wed Nov 29 20:22:58 2006 @@ -7,10 +7,10 @@ <blurb>Resources:</blurb> <list> - <bullet>*Download*: http://ez.no/download/ez_components</bullet> + <bullet>*Download*: http://ez.no/ezcomponents/download</bullet> <bullet>*Documentation*: http://ez.no/doc/components/overview</bullet> <bullet>*Mailinglist*: http://lists.ez.no/mailman/listinfo/components</bullet> - <bullet>*Forum*: http://ez.no/community/forum/ez_components</bullet> + <bullet>*IRC*: #ezcomponents @ Freenode</bullet> <bullet>*These Slides*: :-:url:-:</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/time/improvements-overview.xml?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/time/improvements-overview.xml diff -u presentations/slides/time/improvements-overview.xml:1.3 presentations/slides/time/improvements-overview.xml:1.4 --- presentations/slides/time/improvements-overview.xml:1.3 Thu Nov 2 12:22:22 2006 +++ presentations/slides/time/improvements-overview.xml Wed Nov 29 20:22:58 2006 @@ -4,7 +4,10 @@ <subtitle>Improvements</subtitle> <list> - <bullet>64 bit timestamps</bullet> + <bullet>"Using a (signed) 64-bit value introduces a new wraparound date + in about 290 billion years, on Sunday, December 4, 292,277,026,596. + However, this problem is not widely regarded as a pressing + issue."</bullet> <bullet>~strtotime()~ has been rewritten</bullet> <bullet>Nothing is Operating System dependent</bullet> <bullet>Full support for timezones, DST, date modifications</bullet> http://cvs.php.net/viewvc.cgi/presentations/slides/toolbox/goals-library.xml?r1=1.6&r2=1.7&diff_format=u Index: presentations/slides/toolbox/goals-library.xml diff -u presentations/slides/toolbox/goals-library.xml:1.6 presentations/slides/toolbox/goals-library.xml:1.7 --- presentations/slides/toolbox/goals-library.xml:1.6 Thu Sep 14 19:51:56 2006 +++ presentations/slides/toolbox/goals-library.xml Wed Nov 29 20:22:58 2006 @@ -4,6 +4,7 @@ <list> <bullet>Provide a solid platform for PHP application development</bullet> + <bullet>Don't force a structure: no "framework"</bullet> <bullet>Clean and simple API</bullet> <bullet>Excellent documentation</bullet> <bullet>Keep backward compatibility for longer periods of time</bullet> http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/dr_mail_test.php?r1=1.1&r2=1.2&diff_format=u Index: presentations/slides/xdebug/dr_mail_test.php diff -u presentations/slides/xdebug/dr_mail_test.php:1.1 presentations/slides/xdebug/dr_mail_test.php:1.2 --- presentations/slides/xdebug/dr_mail_test.php:1.1 Thu Mar 30 17:07:16 2006 +++ presentations/slides/xdebug/dr_mail_test.php Wed Nov 29 20:22:58 2006 @@ -4,7 +4,7 @@ error_reporting(E_ALL); $parser = new ezcMailParser(); -$set = new ezcSingleFileSet( dirname(__FILE__).'/ezcmailtest.mail' ); +$set = new ezcMailFileSet( array( dirname(__FILE__).'/ezcmailtest.mail' ) ); echo "Memory: ", xdebug_memory_usage(), " bytes\n\n"; $mail = $parser->parseMail( $set ); http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/ezc_mail_setup.php?r1=1.1&r2=1.2&diff_format=u Index: presentations/slides/xdebug/ezc_mail_setup.php diff -u presentations/slides/xdebug/ezc_mail_setup.php:1.1 presentations/slides/xdebug/ezc_mail_setup.php:1.2 --- presentations/slides/xdebug/ezc_mail_setup.php:1.1 Thu Mar 30 17:07:16 2006 +++ presentations/slides/xdebug/ezc_mail_setup.php Wed Nov 29 20:22:58 2006 @@ -137,43 +137,5 @@ } -class ezcSingleFileSet implements ezcMailParserSet -{ - private $fp = null; - - public function __construct( $file ) - { - $fp = fopen( $file, 'r' ); - if( $fp == false ) - { - throw new Exception( "Could not open file $file for testing." ); - } - $this->fp = $fp; - } - - public function getNextLine() - { - if( feof( $this->fp ) ) - { - if( $this->fp != null ) - { - fclose( $this->fp ); - $this->fp = null; - } - return null; - } - $next = rtrim( fgets( $this->fp ), "\r\n" ); - if( $next == "" && feof( $this->fp ) ) // eat last linebreak - { - return null; - } - return $next; - } - - public function nextMail() - { - return false; - } -} ?> http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/how-to-install.xml?r1=1.1&r2=1.2&diff_format=u Index: presentations/slides/xdebug/how-to-install.xml diff -u presentations/slides/xdebug/how-to-install.xml:1.1 presentations/slides/xdebug/how-to-install.xml:1.2 --- presentations/slides/xdebug/how-to-install.xml:1.1 Thu Mar 30 17:07:16 2006 +++ presentations/slides/xdebug/how-to-install.xml Wed Nov 29 20:22:58 2006 @@ -9,9 +9,9 @@ <blurb>Without PEAR:</blurb> <list class="numbered"> - <bullet>wget http://xdebug.org/files/xdebug-2.0.0beta5.tgz</bullet> - <bullet>tar -xvzf xdebug-2.0.0beta5.tgz</bullet> - <bullet>cd xdebug-2.0.0beta5</bullet> + <bullet>wget http://xdebug.org/files/xdebug-2.0.0RC1.tgz</bullet> + <bullet>tar -xvzf xdebug-2.0.0RC1.tgz</bullet> + <bullet>cd xdebug-2.0.0RC1</bullet> <bullet>phpize</bullet> <bullet>./configure</bullet> <bullet>make</bullet> http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/infinite.png?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/xdebug/infinite.png http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/request-vars.png?r1=1.1&r2=1.2&diff_format=u Index: presentations/slides/xdebug/request-vars.png http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/stacktrace3b.png?r1=1.1&r2=1.2&diff_format=u Index: presentations/slides/xdebug/stacktrace3b.png http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/var_dump.png?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/xdebug/var_dump.png http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/which-code-do-i-use.xml?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/xdebug/which-code-do-i-use.xml diff -u presentations/slides/xdebug/which-code-do-i-use.xml:1.3 presentations/slides/xdebug/which-code-do-i-use.xml:1.4 --- presentations/slides/xdebug/which-code-do-i-use.xml:1.3 Wed Jun 28 10:02:58 2006 +++ presentations/slides/xdebug/which-code-do-i-use.xml Wed Nov 29 20:22:58 2006 @@ -11,5 +11,5 @@ xdebug_get_code_coverage(); xdebug_stop_code_coverate();</example> <break/> - <link target="new" href="http://kossu/coverage/index.htm">demo</link> + <link target="new" href="http://kossu/coverage/index.html">demo</link> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/xdebug/xdebug-var-dump.xml?r1=1.3&r2=1.4&diff_format=u Index: presentations/slides/xdebug/xdebug-var-dump.xml diff -u presentations/slides/xdebug/xdebug-var-dump.xml:1.3 presentations/slides/xdebug/xdebug-var-dump.xml:1.4 --- presentations/slides/xdebug/xdebug-var-dump.xml:1.3 Wed Jun 28 10:02:58 2006 +++ presentations/slides/xdebug/xdebug-var-dump.xml Wed Nov 29 20:22:58 2006 @@ -4,8 +4,12 @@ <image filename="var_dump.png" align="center" pdf-scale="0.7"/> <break lines="2"/> - <blurb>%&lt;?php%</blurb> - <blurb>%xdebug_var_dump(); // or just var_dump()%</blurb> - <blurb>%?>%</blurb> + <example><![CDATA[<?php +ini_set( 'xdebug.var_display_max_data', 25 ); +ini_set( 'xdebug.var_display_max_depth', 4 ); + +xdebug_var_dump(); // or just var_dump() +?>]]></example> +<break lines="2"/> </slide> http://cvs.php.net/viewvc.cgi/presentations/php6-unicode-ffm2006.xml?view=markup&rev=1.1 Index: presentations/php6-unicode-ffm2006.xml +++ presentations/php6-unicode-ffm2006.xml <?xml version="1.0" encoding="iso-8859-1"?> <presentation template="css" navmode="html" navbarbackground="#4373b4" navbartopiclinks="0" navColor="#f1fbff" logo1="" stylesheet="presentations/slides/perf/ezp.css" backgroundfixed="1" > <topic>Localization and Internationalization</topic> <title>PHP 6 and Unicode</title> <event>International PHP Conference</event> <location>Frankfurt, Germany</location> <date>November 7th, 2006</date> <speaker>Derick Rethans</speaker> <email>dr@ez.no</email> <url>http://derickrethans.nl/talks.php</url> <slide>slides/clustering/title.xml</slide> <!-- UNICODE --> <slide>slides/i18nl10n/what-languages.xml</slide> <!-- what is the problem actually? --> <slide>slides/i18nl10n/challenges2.xml</slide> <slide>slides/i18nl10n/sorting.xml</slide> <slide>slides/i18nl10n/convert.xml</slide> <slide>slides/i18nl10n/php-can-do-it-now.xml</slide> <slide>slides/i18nl10n/php-now-iconv.xml</slide> <slide>slides/i18nl10n/php-now-mbstring.xml</slide> <slide>slides/i18nl10n/php-now-locales.xml</slide> <!-- UNICODE --> <slide>slides/i18nl10n/unicode.xml</slide> <slide>slides/i18nl10n/composition.xml</slide> <slide>slides/i18nl10n/properties.xml</slide> <!-- PHP SOON --> <slide>slides/i18nl10n/goals-1.xml</slide> <slide>slides/i18nl10n/basics-1.xml</slide> <slide>slides/i18nl10n/surrogates.xml</slide> <!-- how does the encoding work? --> <slide>slides/i18nl10n/icu.xml</slide> <slide>slides/i18nl10n/roadmap.xml</slide> <slide>slides/i18nl10n/unicode-semantics.xml</slide> <!-- STRINGS --> <slide>slides/i18nl10n/string-types.xml</slide> <slide>slides/i18nl10n/string-literals.xml</slide> <slide>slides/i18nl10n/characters-not-bytes.xml</slide> <slide>slides/i18nl10n/upgrading-locale.xml</slide> <slide>slides/i18nl10n/locale-example.xml</slide> <slide>slides/i18nl10n/locale-example2.xml</slide> <slide>slides/i18nl10n/locale-example-arrays.xml</slide> <slide>slides/i18nl10n/iterator-example.xml</slide> <!-- DIFFERENT ENCODINGS --> <slide>slides/i18nl10n/encoding-overview.xml</slide> <slide>slides/i18nl10n/script-encoding.xml</slide> <slide>slides/i18nl10n/script-encoding-pragma.xml</slide> <slide>slides/i18nl10n/script-encoding-fun1.xml</slide> <slide>slides/i18nl10n/script-encoding-fun2.xml</slide> <slide>slides/i18nl10n/runtime-encoding.xml</slide> <slide>slides/i18nl10n/http-output-encoding.xml</slide> <slide>slides/i18nl10n/stream-encoding1.xml</slide> <slide>slides/i18nl10n/stream-encoding2.xml</slide> <slide>slides/i18nl10n/stream-encoding3.xml</slide> <slide>slides/i18nl10n/translit1.xml</slide> <slide>slides/i18nl10n/fallback-encoding.xml</slide> <!-- EXIT --> <slide>slides/i18nl10n/when.xml</slide> <slide>slides/i18nl10n/resources.xml</slide> <!-- resources --> </presentation> http://cvs.php.net/viewvc.cgi/presentations/xdebug-brasil6.xml?view=markup&rev=1.1 Index: presentations/xdebug-brasil6.xml +++ presentations/xdebug-brasil6.xml <?xml version="1.0" encoding="iso-8859-1"?> <presentation template="css" navmode="html" navbarbackground="#4373b4" navbartopiclinks="0" navColor="#f1fbff" logo1="" stylesheet="presentations/slides/perf/ezp.css" backgroundfixed="1" > <topic>Debugging</topic> <title>Xdebug</title> <event>PHP Conference Brasil</event> <location>São Paulo, Brasil</location> <date>Dec 2nd, 2006</date> <speaker>Derick Rethans</speaker> <email>dr@ez.no</email> <url>http://files.derickrethans.nl/xdebug-brasil6.pdf</url> <slide>slides/xdebug/title.xml</slide> <!-- INTRODUCTION --> <slide>slides/xdebug/why-debugger1.xml</slide> <slide>slides/xdebug/why-debugger2.xml</slide> <slide>slides/xdebug/why-debugger3.xml</slide> <slide>slides/xdebug/how-to-install.xml</slide> <slide>slides/xdebug/how-to-install2.xml</slide> <slide>slides/xdebug/how-to-install-win.xml</slide> <slide>slides/xdebug/how-to-install3.xml</slide> <slide>slides/xdebug/why-crash.xml</slide> <!-- max nesting, function trace --> <slide>slides/xdebug/where-error.xml</slide> <slide>slides/xdebug/debug-req-vars.xml</slide> <slide>slides/xdebug/xdebug-var-dump.xml</slide> <slide>slides/xdebug/how-many-functions.xml</slide> <slide>slides/xdebug/how-much-time.xml</slide> <slide>slides/xdebug/how-much-memory.xml</slide> <slide>slides/xdebug/wtf-happens.xml</slide> <slide>slides/xdebug/live-demo.xml</slide> <slide>slides/xdebug/which-code-do-i-use.xml</slide> <slide>slides/xdebug/profiling.xml</slide> <slide>slides/xdebug/profiling2.xml</slide> <slide>slides/xdebug/live-demo.xml</slide> <slide>slides/xdebug/analyse-running-script.xml</slide> <slide>slides/xdebug/live-demo.xml</slide> <slide>slides/xdebug/resources.xml</slide> </presentation> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/example-persistentobject-databaseschema-tiein.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/example-persistentobject-databaseschema-tiein.xml +++ presentations/slides/ezc/example-persistentobject-databaseschema-tiein.xml <?xml version="1.0" encoding="utf-8"?> <slide> <title>PersistentObjectDatabaseSchemaTiein</title> <blurb>Creating definition files from the database:</blurb> <break/> <example><![CDATA[php pear/ezc/PersistentObjectDatabaseSchemaTiein/rungenerator.php -f mysql -s mysql://root@localhost/workshop data/persistentobject-defs]]></example> <break lines="3"/> <blurb>Often the generated definition files should be changed, for example to change class names and/or column names.</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/imageconversion-structure.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/imageconversion-structure.xml +++ presentations/slides/ezc/imageconversion-structure.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>ImageConversion</title> <subtitle>Ideas</subtitle> <list> <bullet>Transformations can be applied to images</bullet> <bullet>Each transformation consists of one or more filters</bullet> </list> <break lines="2"/> <blurb>Available filters are:</blurb> <list> <bullet>*ezcImageColorspaceFilters*: colorspace</bullet> <bullet>*ezcImageGeometryFilters*: crop, scale, scaleExact, scaleHeight, scalePercent, scaleWidth</bullet> <bullet>*ezcImageWatermarkFilters*: watermarkAbsolute, watermarkPercent</bullet> <bullet>*ezcImageEffectFilters*: border, noise, swirl</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/mail-structure.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/mail-structure.xml +++ presentations/slides/ezc/mail-structure.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Mail</title> <subtitle>Parsed Mail Structure</subtitle> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/template-custom.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/template-custom.xml +++ presentations/slides/ezc/template-custom.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Template Syntax</title> <subtitle>Custom Functions</subtitle> <blurb>Allows you to extend the template language:</blurb><break/> <example><![CDATA[string_to_time( $message->logtime )]]></example> <break lines="2"/> <example><![CDATA[<?php class StringToTimeCall implements ezcTemplateCustomFunction { public static function getCustomFunctionDefinition( $name ) { if ( $name == "string_to_time" ) { $def = new ezcTemplateCustomFunctionDefinition(); $def->class = __CLASS__; $def->method = "strtotime"; $def->parameters = array("timestring"); return $def; } return false; } public static function strtotime( $string ) { return strtotime( $string ); } } $config = ezcTemplateConfiguration::getInstance(); $config->addExtension( 'StringToTimeCall' ); ?>]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/template-syntax1.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/template-syntax1.xml +++ presentations/slides/ezc/template-syntax1.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Template Syntax</title> <blurb>Variable declaration</blurb> <list type="number"> <bullet>%{use $parameter}%</bullet> <bullet>%{var $i, $j}%</bullet> </list> <break lines="2"/> <blurb>Assigments and expressions</blurb> <list> <bullet>Assignments: =, +=, -=, *=, >=, /=, %=</bullet> <bullet>Arithmetic operators: +, -, \*, /, %</bullet> <bullet>Comparison operators: ==, ===, !=, !==, <, >, <=, >=</bullet> <bullet>Logical operators: ||, &&, !</bullet> <bullet>increment, decrement: $v++, $v--, ++$v, --$v</bullet> <bullet>*Note:* Assignments cannot be used inside an expression: %{if $a = 2}%</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/template-syntax2.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/template-syntax2.xml +++ presentations/slides/ezc/template-syntax2.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Template Syntax</title> <subtitle>Extra features</subtitle> <blurb>Delimiter:</blurb><break/> <example><![CDATA[{foreach array("one", "two", "three") as $n} {$n}{delimiter}, {/delimiter} {/foreach}]]></example> <break lines="3"/> <blurb>Cycle:</blurb><break/> <example><![CDATA[{var $elements = 0..(10 + 2)} {cycle $color = array( "#FF0000", "#00FF00" )} <table> {foreach $elements as $el increment $color offset 3 limit 5} <tr style="background-color: {$color}"> <td>Number</td><td>{$el}</td> </tr> {/foreach} </table>]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository.xml +++ presentations/slides/ezc/workshop/assignment-base-repository.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Class Repository (1/3)</title> <subtitle>~15 minutes</subtitle> <blurb>In the directory "%~/include/persistent_classes%" create four files containing classes:</blurb> <list type="number"> <bullet>%category.php% containing the class %wpcCategory% with the attributes: |ff0000|$id| and |ff0000|$name|.</bullet> <bullet>%image.php% containing the class %wpcImage% with the attributes: |ff0000|$id|, |ff0000|$messageId|, |ff0000|$category_id|, |ff0000|$description|, |ff0000|$send_time|, |ff0000|$orig_x_size|, |ff0000|$orig_y_size|, |ff0000|$owner_email|, |ff0000|$owner_name| and |ff0000|$shutterspeed|.</bullet> <bullet>%image_file.php% containing the class %wpcImageFile% with the attributes: |ff0000|$id|, |ff0000|$image_id|, |ff0000|$type| and |ff0000|$data|.</bullet> <bullet>%log.php% containing the class %wpcLog% with the attributes: |ff0000|$id|, |ff0000|$logtime|, |ff0000|$src|, |ff0000|$category| and |ff0000|$message|.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository2.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository2.xml +++ presentations/slides/ezc/workshop/assignment-base-repository2.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Class Repository (2/3)</title> <subtitle>~15 minutes</subtitle> <blurb>Use the following template for classes:</blurb> <example><![CDATA[<?php class wpcImageFile { private $id = null; public $image_id = null; public $type = null; public $data = null; public function getState() { $result = array(); $result['id'] = $this->id; $result['image_id'] = $this->image_id; $result['type'] = $this->type; $result['data'] = $this->data; return $result; } public function setState( array $properties ) { foreach ( $properties as $key => $value ) { $this->$key = $value; } } } ?> ]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository3.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository3.xml +++ presentations/slides/ezc/workshop/assignment-base-repository3.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Class Repository (3/3)</title> <subtitle>~15 minutes</subtitle> <blurb>In the directory %~/include/persistent_classes/autoload%, create the following files:</blurb> <break lines="2"/> <blurb>category_autoload.php</blurb> <example><![CDATA[<?php return array( 'wpcCategory' => 'category.php', ); ?>]]></example> <break lines="2"/> <blurb>image_autoload.php</blurb> <example><![CDATA[<?php return array( 'wpcImage' => 'image.php', 'wpcImageFile' => 'image_file.php', ); ?>]]></example> <break lines="2"/> <blurb>log_autoload.php</blurb> <example><![CDATA[<?php return array( 'wpcLog' => 'log.php', ); ?>]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository4.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository4.xml +++ presentations/slides/ezc/workshop/assignment-base-repository4.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Persistent Object Definitions (1/3)</title> <subtitle>~15 minutes</subtitle> <blurb>Change the include/ezc-setup.php file to include:</blurb> <example><![CDATA[<?php ezcBase::addClassRepository( dirname( __FILE__ ) . '/persistent_classes', null, 'wpc' ); ?>]]></example> <break lines="3"/> <blurb>Create the persistent object definition files:</blurb> <example><![CDATA[php pear/ezc/PersistentObjectDatabaseSchemaTiein/rungenerator.php -f mysql -s mysql://root@localhost/workshop data/persistentobject-defs]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository5.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository5.xml +++ presentations/slides/ezc/workshop/assignment-base-repository5.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Persistent Object Definitions (2/3)</title> <subtitle>~15 minutes</subtitle> <blurb>Modify the generated files in %~/data/persistentobject-defs%:</blurb> <list type="number"> <bullet>Rename the files to %wpccategory.php%, %wpcimage.php%, %wpcimagefile.php% and %wpclog.php%.</bullet> <bullet>In the files, change %$def->class% to the correct classnames: %wpcImage%, %wpcImageFile%, %wpcCategory% and %wpcLog%.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base-repository6.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base-repository6.xml +++ presentations/slides/ezc/workshop/assignment-base-repository6.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Persistent Object Definitions (3/3)</title> <subtitle>~15 minutes</subtitle> <blurb>Add information about relations to the following files:</blurb> <break lines="2"/> <blurb>~/data/persistentobject-defs/wpccategory.php:</blurb> <example><![CDATA[<?php $def->relations['wpcImage'] = new ezcPersistentOneToManyRelation( "category", "image" ); $def->relations['wpcImage']->columnMap = array( new ezcPersistentSingleTableMap( 'id', 'category_id' ) ); ?>]]></example> <break lines="2"/> <blurb>~/data/persistentobject-defs/wpcimage.php:</blurb> <example><![CDATA[<?php $def->relations['wpcImageFile'] = new ezcPersistentOneToManyRelation( "image", "image_file" ); $def->relations['wpcImageFile']->columnMap = array( new ezcPersistentSingleTableMap( 'id', 'image_id' ) ); ?>]]></example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-base.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-base.xml +++ presentations/slides/ezc/workshop/assignment-base.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Installation</title> <subtitle>~10 minutes</subtitle> <blurb>Configure pear as follows:</blurb> <example type="shell"> pear config-set php_dir /home/ezc/pear pear config-set data_dir /home/ezc/pear-data pear config-set test_dir /home/ezc/pear-test pear config-set doc_dir /home/ezc/pear-doc pear config-set preferred_state alpha</example> <break lines="3"/> <blurb>Install the components with the PEAR installer.</blurb> <break lines="3"/> <blurb>Create the script "%~/include/ezc-setup.php%" that sets up the components' autoloading mechanism. Set the include path to "%/home/ezc/pear:/home/ezc:.%".</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-configuration.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-configuration.xml +++ presentations/slides/ezc/workshop/assignment-configuration.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Configuration</title> <subtitle>~15 minutes</subtitle> <list> <bullet>Create the file "watermark.ini" in %/home/ezc/data/configuration% with the following contents:</bullet> </list> <example>[size] max_width=900 max_height=600</example> <list> <bullet>Extend the %scripts/read-mail.php% script to use the configurable sizes for the watermarked image.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-eventlog.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-eventlog.xml +++ presentations/slides/ezc/workshop/assignment-eventlog.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: EventLog</title> <subtitle>~30 minutes</subtitle> <list> <bullet>Extend the image-details.php script to log how often an image has been viewed. Use the following writer definition:</bullet> </list> <example><![CDATA[<?php $db = ezcDbFactory::create( 'mysql://root@localhost/workshop' ); $writer = new ezcLogDatabaseWriter( $db, "log" ); $writer->source = 'src'; $writer->datetime = 'logtime'; $writer->imageid = 'imageid'; ?>]]></example> <list> <bullet>Make sure to log the imageid in a custom parameter to the logger.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-graph.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-graph.xml +++ presentations/slides/ezc/workshop/assignment-graph.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Graph</title> <subtitle>~30 minutes</subtitle> <list> <bullet>View the graph.php to see whether the logging works.</bullet> <bullet>And then start modifying the render options. Maybe there is a price for the best looking graph ;-)</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-imageconversion.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-imageconversion.xml +++ presentations/slides/ezc/workshop/assignment-imageconversion.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: ImageAnalysis & ImageConversion</title> <subtitle>~25 minutes</subtitle> <blurb>Enhance the shell script to extract the photo's shutterspeed with ImageAnalysis and print the results to standard output as well.</blurb> <break lines="3"/> <blurb>Enhance the script to generate three images from the original image. Those images should be generated to %/tmp%:</blurb> <list type="number"> <bullet>A greyscale thumbnail in the size of maximum 50x50: %small_thumb.jpg% (type 1)</bullet> <bullet>A thumbnail in the size of maximum 100x100: %large_thumb.jpg% (type 2)</bullet> <bullet>A resized version (800x600) but added on top a watermark (%logo.png%) in the top-left corner: %watermark.jpg% (type 3)</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-mail1.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-mail1.xml +++ presentations/slides/ezc/workshop/assignment-mail1.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Mail</title> <subtitle>~20 minutes</subtitle> <list> <bullet>Send a mail message with Thunderbird (Applications->Internet->Icedove Mail Client) to ezc@workshop.ez.no.local and attach a JPEG image (you can find them in /home/ezc/data/workshop-images).</bullet> <bullet>Press "Get Mail" to check if the mail has been sent correctly. The mail should also stay on the server.</bullet> <bullet>Write a small console PHP script "~/scripts/import-mail.php" that reads all mails in the mailbox and writes to standard output: sender name, sender email address, filename of the parser attachment, the body of the first text part and the message ID.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-persistent-object1.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-persistent-object1.xml +++ presentations/slides/ezc/workshop/assignment-persistent-object1.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: PersistentObject</title> <subtitle>~30 minutes</subtitle> <blurb>In the %~/scripts/read-mail.php% script create a function that uses the ezcPersistentSession:</blurb> <list type="number"> <bullet>Check if the category (the subject of the mail message) already exists, and store the ID of the category in a variable. (Hint: %$q = $session->createFindQuery();%</bullet> <bullet>If it does not exist, create the category and store the new ID in a variable. (Hint: %$session->save( $cat );%)</bullet> <bullet>Check if the mail/image already has been added to the database. (Hint: Use the messageId property of the wpcImage class)</bullet> <bullet>If the image does not exist, create a new one and store it in the database.</bullet> <bullet>Add the 4 related wpcImageFile objects. Use %$session->addRelatedObject();% to link them to the image object.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-template1.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-template1.xml +++ presentations/slides/ezc/workshop/assignment-template1.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Template (1/3)</title> <subtitle>Image overview: ~45 minutes</subtitle> <list> <bullet>Create a PHP script "%~/www/index.php%"</bullet> <bullet>Set-up the Template component's templatePath and compilePath to %/home/ezc/data/templates%.</bullet> <bullet>Retrieve all %wpcCategory% objects with ezcPersistentSession, and send the resulting array *and* the session itself to a template called "%index.ezt%".</bullet> <bullet>Create the template %~/data/templates/index.ezt% that lists all the categories as "h2" elements.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-template2.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-template2.xml +++ presentations/slides/ezc/workshop/assignment-template2.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Template (2/3)</title> <subtitle>Image overview: ~45 minutes</subtitle> <list> <bullet>Include the %include/template_function_call.php% file in the %index.php% script and use the %addExtension()% method of the ezcTemplateConfiguration to add it to the template system.</bullet> <bullet>In the template %index.ezt% use the following code to retrieve all related images for each category:</bullet> </list> <example>{foreach $categories as $category} <h2>{$category->name}</h2> {$categoryImages = call( $session, "getRelatedObjects", array( $category, "wpcImage" ))}</example> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/assignment-template3.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/assignment-template3.xml +++ presentations/slides/ezc/workshop/assignment-template3.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>Assignment: Template (3/3)</title> <subtitle>Image overview: ~45 minutes</subtitle> <list> <bullet>Then loop over the %$categoryImages% and display them as:</bullet> </list> <example><![CDATA[<a href='image-details.php?id=42'> <img src='image.php?id=42&type=1'/> </a>]]></example> <list> <bullet>If everything is ready, check the result with Firefox.</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/configuration.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/configuration.xml +++ presentations/slides/ezc/workshop/configuration.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Configuration</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/database.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/database.xml +++ presentations/slides/ezc/workshop/database.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Database</blurb> <blurb class="large_blurb_center">DatabaseSchema</blurb> <blurb class="large_blurb_center">PerisistentObject</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/eventlog.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/eventlog.xml +++ presentations/slides/ezc/workshop/eventlog.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">EventLog</blurb> <blurb class="large_blurb_center">EventLogDatabaseTiein</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/graph.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/graph.xml +++ presentations/slides/ezc/workshop/graph.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Graph</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/installing.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/installing.xml +++ presentations/slides/ezc/workshop/installing.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Installation</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/introduction.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/introduction.xml +++ presentations/slides/ezc/workshop/introduction.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Introduction</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/mail-image.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/mail-image.xml +++ presentations/slides/ezc/workshop/mail-image.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Mail</blurb> <blurb class="large_blurb_center">ImageConversion</blurb> <blurb class="large_blurb_center">ImageAnalysis</blurb> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/program.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/program.xml +++ presentations/slides/ezc/workshop/program.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <subtitle>Program</subtitle> <list> <bullet>Introduction (30 mins)</bullet> <bullet>Installing the components (15 mins)</bullet> <bullet>Mail, ImageConversion and ImageAnalysis (1 hour)</bullet> <bullet>Database, DatabaseSchema and PersistentObject (1 hour)</bullet> <bullet>Template (1 hour)</bullet> <bullet>Configuration (30 mins)</bullet> <bullet>EventLog (30 mins)</bullet> <bullet>Graph (1 hour)</bullet> </list> </slide> http://cvs.php.net/viewvc.cgi/presentations/slides/ezc/workshop/template.xml?view=markup&rev=1.1 Index: presentations/slides/ezc/workshop/template.xml +++ presentations/slides/ezc/workshop/template.xml <?xml version="1.0" encoding="iso-8859-1"?> <slide fontsize="6em"> <title>eZ components workshop</title> <break lines="15"/> <blurb class="large_blurb_center">Template</blurb> </slide>