CVS update: php3/doc/chapters
| From: | eschmid | Date: | Sun, 16 May 1999 14:14:47 +0000 |
| Subject: | CVS update: php3/doc/chapters | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-5687@lists.php.net to get a copy of this message | ||
Date: Sunday May 16, 1999 @ 10:14
Author: eschmid
Update of /repository/php3/doc/chapters
In directory php:/tmp/cvs-serv13081
Modified Files:
lang-syntax.sgml
Log Message:
This should show Colin's fundamental introduction to array manipulation.
Index: php3/doc/chapters/lang-syntax.sgml
diff -u php3/doc/chapters/lang-syntax.sgml:1.35 php3/doc/chapters/lang-syntax.sgml:1.36
--- php3/doc/chapters/lang-syntax.sgml:1.35 Tue May 11 13:26:38 1999
+++ php3/doc/chapters/lang-syntax.sgml Sun May 16 10:14:47 1999
@@ -645,6 +645,8 @@
</programlisting>
</informalexample>
+ </sect1>
+
<sect1 id="variable-arrays">
<title>Array manipulation</title>
@@ -658,7 +660,7 @@
functions, or you can explicitly set each array element value.
<informalexample>
- <programlisting>
+ <programlisting role="php">
$a[0] = "abc";
$a[1] = "def";
$b["foo"] = 13;
@@ -670,7 +672,7 @@
the array.
<informalexample>
- <programlisting>
+ <programlisting role="php">
$a[] = "hello"; // $a[2] == "hello"
$a[] = "world"; // $a[3] == "world"
</programlisting>
@@ -694,6 +696,8 @@
traverse an array is to use the <function>each</function>
function.
+ </sect2>
+
<sect2 id="variable-arrays.multi-dim">
<title>Multi-Dimensional Arrays</title>
@@ -702,7 +706,7 @@
dimension of the array, you add another [key] value to the end:
<informalexample>
- <programlisting>
+ <programlisting role="php">
$a[1] = $f; # one dimensional examples
$a["foo"] = $f;
@@ -721,7 +725,7 @@
the one-dimensional array in the same way:
<informalexample>
- <programlisting>
+ <programlisting role="php">
# Example 1:
$a["color"] = "red";
@@ -747,8 +751,8 @@
multi-dimensional arrays:
<informalexample>
- <programlisting>
-<?
+ <programlisting role="php">
+<?
$a = array(
"apple" => array(
"color" => "red",
@@ -771,6 +775,10 @@
?>
</programlisting>
</informalexample>
+
+ </sect2>
+
+ </sect1>
</chapter>
--
PHP Development Mailing List http://www.php.net/
To unsubscribe send an empty message to php-dev-unsubscribe@lists.php.net
For help: php-dev-help@lists.php.net