goba Tue Jul 10 08:29:36 2001 EDT
Modified files:
/phpdoc/en/language control-structures.xml
Log:
Some ugly errors corrected (eg. comment without an end,
constant definition, do..while added to the break list, etc.)
Index: phpdoc/en/language/control-structures.xml
diff -u phpdoc/en/language/control-structures.xml:1.33
phpdoc/en/language/control-structures.xml:1.34
--- phpdoc/en/language/control-structures.xml:1.33 Sat Jul 7 17:27:19 2001
+++ phpdoc/en/language/control-structures.xml Tue Jul 10 08:29:36 2001
@@ -576,7 +576,7 @@
}
}
-/* foreach example 5: dynamic arrays
+/* foreach example 5: dynamic arrays */
foreach(array(1, 2, 3, 4, 5) as $v) {
print "$v\n";
@@ -590,8 +590,9 @@
<title><literal>break</literal></title>
<simpara>
<literal>break</literal> ends execution of the current
- <literal>for</literal>, <literal>while</literal>,
- <literal>foreach</literal> or <literal>switch</literal> structure.
+ <literal>for</literal>, <literal>foreach</literal>
+ <literal>while</literal>, <literal>do..while</literal> or
+ <literal>switch</literal> structure.
</simpara>
<simpara>
<literal>break</literal> accepts an optional numeric argument
@@ -827,8 +828,8 @@
<sect1 id="control-structures.declare">
<title><literal>declare</literal></title>
<para>
- The <literal>declare</literal> construct is used to is
- used to set execution directives for a block of code.
+ The <literal>declare</literal> construct is used to
+ set execution directives for a block of code.
The syntax of <literal>declare</literal> is similiar to
the syntax of other flow control constructs:
<informalexample>
@@ -1278,7 +1279,7 @@
<title>utils.inc</title>
<programlisting role="php">
<?php
-define(PHPVERSION, floor(phpversion()));
+define("PHPVERSION", floor(phpversion()));
echo "GLOBALS ARE NICE\n";
function goodTea() {
return "Oolong tea tastes good!";