com presentations: Wrong example type there: etsy15.html slides/intro/bc7.xml
[email protected] (Rasmus Lerdorf) Mon, 09 Nov 2015 20:08:28 +0000
| Newsgroups | php.pres |
|---|---|
| Message-ID | <[email protected]> |
Commit: 7773455e9ee9ff06acad16348627e0c130543b09 Author: Rasmus Lerdorf <[email protected]> Mon, 9 Nov 2015 12:08:28 -0800 Parents: f4d0cdccad07fc9b814e1614721c2b4ebaf9a5e3 Branches: master Link: http://git.php.net/?p=presentations.git;a=commitdiff;h=7773455e9ee9ff06acad16348627e0c130543b09 Log: Wrong example type there Changed paths: M etsy15.html M slides/intro/bc7.xml Diff: diff --git a/etsy15.html b/etsy15.html index 66b8eb6..f61f33c 100644 --- a/etsy15.html +++ b/etsy15.html @@ -1018,12 +1018,12 @@ KiB Swap: 0 total, 0 used, 0 free. 13514376 cached Mem </section> <section id="bc7_1"> <p class="p" style="font-size:1.1em;text-align:left;">Left-to-right semantics for complicated expressions</p> - <pre><code class="ini" data-trim style="font-size:1.1em;">$$foo['bar']['baz'] // interpreted as ($$foo)['bar']['baz'] + <pre><code class="php" data-trim style="font-size:1.1em;">$$foo['bar']['baz'] // interpreted as ($$foo)['bar']['baz'] $foo->$bar['baz'] // interpreted as ($foo->$bar)['baz'] $foo->$bar['baz']() // interpreted as ($foo->$bar)['baz']() Foo::$bar['baz']() // interpreted as (Foo::$bar)['baz']()</code></pre> <p class="p" style="font-size:0.8em;text-align:left;">To restore the previous behaviour add explicit curly braces:</p> - <pre><code class="ini" data-trim style="font-size:1.1em;">${$foo['bar']['baz']} + <pre><code class="php" data-trim style="font-size:1.1em;">${$foo['bar']['baz']} $foo->{$bar['baz']} $foo->{$bar['baz']}() Foo::{$bar['baz']}()</code></pre> @@ -1031,9 +1031,9 @@ Foo::{$bar['baz']}()</code></pre> </section> <section id="bc7_2"> <p class="p" style="font-size:1.1em;text-align:left;">Removed support for /e (PREG_REPLACE_EVAL) modifier</p> - <pre><code class="ini" data-trim style="font-size:1.1em;">echo preg_replace('/:-:(.*?):-:/e', '$this->pres->\\1', $text);</code></pre> + <pre><code class="php" data-trim style="font-size:1.1em;">echo preg_replace('/:-:(.*?):-:/e', '$this->pres->\\1', $text);</code></pre> <p class="p" style="font-size:0.8em;text-align:left;">Change to:</p> - <pre><code class="ini" data-trim style="font-size:1.1em;">echo preg_replace_callback( + <pre><code class="php" data-trim style="font-size:1.1em;">echo preg_replace_callback( '/:-:(.*?):-:/', function($matches) { return $this->pres->{$matches[1]}; // Careful! diff --git a/slides/intro/bc7.xml b/slides/intro/bc7.xml index 77162c6..afe45e0 100644 --- a/slides/intro/bc7.xml +++ b/slides/intro/bc7.xml @@ -7,7 +7,7 @@ <break lines="1" section="bc7_1"/> <blurb fontsize="1.1em" align="left">Left-to-right semantics for complicated expressions</blurb> -<example fontsize="1.1em" result='0' title="" type="ini"><![CDATA[ +<example fontsize="1.1em" result='0' title="" type="php"><![CDATA[ $$foo['bar']['baz'] // interpreted as ($$foo)['bar']['baz'] $foo->$bar['baz'] // interpreted as ($foo->$bar)['baz'] $foo->$bar['baz']() // interpreted as ($foo->$bar)['baz']() @@ -15,7 +15,7 @@ Foo::$bar['baz']() // interpreted as (Foo::$bar)['baz']() ]]></example> <blurb fontsize="0.8em" align="left">To restore the previous behaviour add explicit curly braces:</blurb> -<example fontsize="1.1em" result='0' title="" type="ini"><![CDATA[ +<example fontsize="1.1em" result='0' title="" type="php"><![CDATA[ ${$foo['bar']['baz']} $foo->{$bar['baz']} $foo->{$bar['baz']}() @@ -25,11 +25,11 @@ Foo::{$bar['baz']}() <break lines="1" section="bc7_2"/> <blurb fontsize="1.1em" align="left">Removed support for /e (PREG_REPLACE_EVAL) modifier</blurb> -<example fontsize="1.1em" result='0' title="" type="ini"><![CDATA[ +<example fontsize="1.1em" result='0' title="" type="php"><![CDATA[ echo preg_replace('/:-:(.*?):-:/e', '$this->pres->\\1', $text); ]]></example> <blurb fontsize="0.8em" align="left">Change to:</blurb> -<example fontsize="1.1em" result='0' title="" type="ini"><![CDATA[ +<example fontsize="1.1em" result='0' title="" type="php"><![CDATA[ echo preg_replace_callback( '/:-:(.*?):-:/', function($matches) {