note 13018 deleted from function.array by felipe
| Newsgroups | php.notes |
|---|---|
| Message-ID | <[email protected]> |
Note Submitter: xftp at yahoo dot com
----
This is a small script that shows how to use an array of a Class.
<?
class test{
var $test1;
var $test2;
}
$a = array();
$a[] = new test;
$a[0]->test1 = 1;
$a[0]->test2 = 1;
$a[1]->test1 = 2;
$a[1]->test2 = 2;
$x = $a[0]->test1;
$y = $a[0]->test2;
echo "$x - $y";
?>