[git] presentations.git branch master updated. 6c12b9b
| From: | rasmus@php.net | Date: | Thu, 02 Feb 2012 20:56:35 +0000 |
| Subject: | [git] presentations.git branch master updated. 6c12b9b | ||
| Groups: | php.pres | ||
| Request: | Send a blank email to pres+get-1770@lists.php.net to get a copy of this message | ||
The branch, master on presentations.git has been updated
via 6c12b9b0b6816490a35521e7a8567322ba1a4bc5 (commit)
from 4ffa5a655b34b86fcdb388087c2691f0d75e2dca (commit)
http://git.php.net/?p=presentations.git;a=log;h=6c12b9b0b6816490a35521e7a8567322ba1a4bc5;hp=4ffa5a655b34b86fcdb388087c2691f0d75e2dca
Summary of changes:
slides/intro/api_yql1.xml | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
-- Log ----------------------------------------
commit 6c12b9b0b6816490a35521e7a8567322ba1a4bc5
Author: Rasmus Lerdorf <rasmus@php.net>
Date: Thu Feb 2 15:50:26 2012 -0500
clean up
diff --git a/slides/intro/api_yql1.xml b/slides/intro/api_yql1.xml
index 640e8eb..1669f1f 100644
--- a/slides/intro/api_yql1.xml
+++ b/slides/intro/api_yql1.xml
@@ -17,7 +17,8 @@ echo "Name: {$name->name}<br />\n";
echo "Gender: {$name->gender}<br />\n";
echo "Countries: ";
$countries='';
-foreach($name->countries->country as $c) $countries.=((string)$c).", ";
+if(count($name->countries->country))
+ foreach($name->countries->country as $c) $countries.=((string)$c).", ";
$countries = rtrim($countries,", ");
echo $countries;
?>
Thank you for your contribution.