phpday talks

This commit is contained in:
Rasmus Lerdorf
2009-05-15 09:54:34 +00:00
parent abdc74ed65
commit 00cecc82b1
3 changed files with 164 additions and 0 deletions

31
phpday1.xml Normal file
View File

@@ -0,0 +1,31 @@
<presentation
template="php2"
navmode="html"
titlecolor="#1111aa"
navbarbackground="url(images/trans-ffffff.png)"
logo1="images/php-med-trans-light.gif"
titlesize="2em"
navbarheight="4.1em"
>
<topic>PHP</topic>
<title>PHP</title>
<event>PHPDay</event>
<location>Verona, Italy</location>
<date>May 15, 2009</date>
<speaker>Rasmus Lerdorf</speaker>
<url>http://talks.php.net/show/phpday1</url>
<twitter>rasmus</twitter>
<slide>slides/intro/titlepage.xml</slide>
<!-- History -->
<slide>slides/fowa/hist1.xml</slide>
<slide>slides/fowa/hist2.xml</slide>
<slide>slides/fowa/hist3.xml</slide>
<slide>slides/fowa/hist4.xml</slide>
<slide>slides/fowa/hist5.xml</slide>
<slide>slides/intro/php53.xml</slide>
</presentation>

53
phpday2.xml Normal file
View File

@@ -0,0 +1,53 @@
<presentation
template="php2"
navmode="html"
titlecolor="#1111aa"
navbarbackground="url(images/trans-ffffff.png)"
logo1="images/php-med-trans-light.gif"
titlesize="2em"
navbarheight="4.1em"
>
<!--
Simple is Hard
-->
<topic>PHP</topic>
<title>Simple is Hard</title>
<event>PHPDay</event>
<location>Verona, Italy</location>
<date>May 15, 2009</date>
<speaker>Rasmus Lerdorf</speaker>
<url>http://talks.php.net/show/phpday2</url>
<twitter>rasmus</twitter>
<slide>slides/intro/titlepage.xml</slide>
<slide>slides/intro/complex.xml</slide>
<slide>slides/intro/complex2.xml</slide>
<!-- Performance -->
<slide>slides/intro/hurdles3.xml</slide>
<slide>slides/intro/scale1.xml</slide>
<slide>slides/intro/modular.xml</slide>
<slide>slides/intro/perf_overall1.xml</slide>
<slide>slides/intro/lac1.xml</slide>
<slide>slides/intro/lac2.xml</slide>
<slide>slides/intro/lac3.xml</slide>
<slide>slides/intro/lac4.xml</slide>
<slide>slides/intro/lac5.xml</slide>
<slide>slides/intro/lac6.xml</slide>
<slide>slides/intro/lac7.xml</slide>
<slide>slides/intro/lac8.xml</slide>
<slide>slides/intro/lac9.xml</slide>
<slide>slides/intro/lac10.xml</slide>
<slide>slides/intro/lac11.xml</slide>
<slide>slides/intro/twit0.xml</slide>
<slide>slides/intro/twit1.xml</slide>
<slide>slides/intro/twit2.xml</slide>
<slide>slides/intro/twit3.xml</slide>
<slide>slides/intro/twit4.xml</slide>
<slide>slides/intro/perf_ref.xml</slide>
</presentation>

80
slides/intro/php53.xml Normal file
View File

@@ -0,0 +1,80 @@
<slide title="PHP 5.3">
<break lines="1" />
<example fontsize="1.4em" result='0' title="Defining a namespace"><![CDATA[<?php
// foo.php
namespace foo;
class bar {
function __construct() {
echo get_called_class();
}
}
?>]]></example>
<example fontsize="1.4em" result='0' title="Using namespaced code"><![CDATA[<?php
require './foo.php';
use foo\bar as b;
$a = new b;
?>]]></example>
<example fontsize="1.4em" hide="1" result='1' title="Output"><![CDATA[foo\bar]]></example>
<example fontsize="1.4em" result='1' title="NOWDOC"><![CDATA[<?php
echo <<< 'EOB'
NOWDOC is to HEREDOC as single quoted $trings are\n
to double quoted $trings in PHP.
EOB;
?>]]></example>
<example fontsize="1.4em" result='1' title="?:"><![CDATA[<?php
echo true ?: 'Hello';
echo false ?: 'World';
?>]]></example>
<example fontsize="1.4em" result='0' title="goto"><![CDATA[<?php
function foo() {
for($i=0, $j=1; $i<10; $i++) {
while($j++) {
if($j == 5) {
goto end;
}
}
}
end:
// run cleanup code
}
?>]]></example>
<example fontsize="1.4em" result="0" title="get_called_class"><![CDATA[<?php
abstract class Singleton {
private static $instances = array();
final public static function getInstance() {
$className = get_called_class();
if(!isset(self::$instances[$className])) {
self::$instances[$className] = new $className();
}
return self::$instances[$className];
}
}
class foo extends Singleton { }
class bar extends Singleton { }
$a = foo::getInstance();
$b = foo::getInstance();
$c = bar::getInstance();
?>]]></example>
<example fontsize="1.4em" result="1" title="DateInterval/DatePeriod"><![CDATA[<?php
$db = new DateTime( '2008-12-31' );
$de = new DateTime( '2009-12-31' );
$di = DateInterval::createFromDateString('third tuesday of next month');
$dp = new DatePeriod($db, $di, $de, DatePeriod::EXCLUDE_START_DATE);
foreach($dp as $dt) {
echo $dt->format( "F jS\n" ) . "<br>\n";
}
?>]]></example>
</slide>