-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
> What I've tried looks something like this:
> 1 : class CBenutzer extends MidgardPerson {
> 2 : var $__test;
> 3 :
> 4 : function CBenutzer ($id) {
> 5 : $user = mgd_get_person ($id);
> 6 :
> 7 : // Do some checks here wether the person is OK
> 8 :
> 9 : $this = $user;
> 10 :
> 11 : }
> 12 :
> 13 : }
Here's wot I did...
class clsSiteCommon {
var $midgard = 0; // Midgard Object
var $u = 0; // User Object
var $a = Array(); // Articles Object Array
function clsSiteCommon(&$midgard = 0)
{
// Copy the midgard Object into the so internal
// fudging makes sense and the class is self contained
// do this using *urgh!* PHP refernces
$this->migard = ($midgard==0)?&$GLOBALS["midgard"]:&$midgard;
// Get the user
$this->u = mgd_get_person($this->midgard->user);
// Now you have the
print $this->u->name;
// variable... not only does this make things easier it also
// means that any other things you do are separated.
}
}
I did it this way because I wanted to give a degree of controll to
the front end developers withoput having to teach them PHP.
- --
Richard
-----BEGIN PGP SIGNATURE-----
Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>
iQA/AwUBO7ptpYS/j9ttdrpZEQLEdQCgolNNDpdgkgf57SlV8Xy4RY3zYGEAoJ5u
8nVb1x/bjjD7RkvW9mXM/PuQ
=mWhW
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]