PDA

View Full Version : can anyone tell me whats going on with this simple bit of code?


rickrichards82
09-04-2009, 01:24 AM
i really don't know whats going on with this bit of code. can someone give me detailed information on whats going on? even a few key words to search for so that i can look up some tutorials? at first i thought they were arrays but then when i looked up arrays i realized that this is not the case. anyone?

$this->registry =& $registry;
$this->userinfo = $userinfo;

Lynne
09-04-2009, 01:37 AM
Object Oriented PHP is what you are looking at. But, that's as far as my 'detailed information' goes, sorry.

rickrichards82
09-04-2009, 02:10 AM
that might be all i need to know. thank you.

Dismounted
09-04-2009, 05:06 AM
$this refers to the object that code is called in.
=& means assign by reference.
$this->registry and $this->userinfo are properties of the project, and in this case, values are being assigned to them.

Those bolded keywords should bring up some material for you to trawl through. :)