[UPHPU] Accessing a Parent Object's Other Variables

Kirk Cerny kirksemail at gmail.com
Mon Jun 22 22:07:28 MDT 2009


This just seems like a really bad idea to me.
You also mentioned that there is a parent class, but I dont see the
extends keyword.

<?php

Class A {

   var $msg = 'Why hello there my old friend';

   function  __construct() {
   }

}


Class B extends A {

   function __construct() {
   }

}



$b = new B();

echo $b->msg;

Kirk Cerny


More information about the UPHPU mailing list