Quoting David Eriksson <[EMAIL PROTECTED]>:
> > This time, the last echo line will get the value of $s1->a and not
> > $s2->a.
> >
> > handle_property_get is only called on the $s1 instance and not on
> the
> > $s2
> > instance of the object.
> >
> > I will write a PHP extension that just shows
Quoting David Eriksson <[EMAIL PROTECTED]>:
> First, look att this piece of pure PHP code:
>
>
>
>
> class S
> {
> var $a;
> var $x;
> }
>
> $s1 = new S();
> $s1->a = 42;
>
> $s2 = new S();
>
> $s2->a = 4711;
> $s2->x = $s1;
>
> echo $s1->a."\n";
>
> $s3 = $s
First, look att this piece of pure PHP code:
a = 42;
$s2 = new S();
$s2->a = 4711;
$s2->x = $s1;
echo $s1->a."\n";
$s3 = $s2->x;
echo $s3->a."\n";
echo $s2->x->a."\n";
?>
All three of the "echo" lines above will output the value 42.
Now consider