The idea of object-oriented programming is much wider than the possibilities of PHP due to its specifics, but even in the existing implementation, it gives the programmer unlimited possibilities. The construct PHP construct is a special method of a class (object) that is called every time an instance of the class is created.
The limitation is that PHP is working at the time of page formation. At the moment when the page is updated or another page of the same site is loading, the desired system of objects is formed again from scratch.
Creating an instance of a class
. , (), , PHP class construct .
- , ( ) . , .
, , (), function construct PHP .
(PHP construct) (). __construct , .
$iUniqueNo, . PHP .
, , , , . , .
parent:: . . , . , - .
, . .
" " - , , , , .
, , - - . , PHP parent construct - .
. public function construct, PHP , .
private - , ?
- , , , .
- PHP construct class , , .
AJAX JavaScript , .
PHP , "", "" , , , - ++.
, "", . , ++, #, Pascal&Delphi. - , .
"" " ". . , ++ #, :
- , , . , , .
, . , . - .
, - .
PHP construct , :
PHP , , .
, . , ( , ), , , .
, . .
A self-preserving system of objects "remembers" the actions of the visitor and the state of the pages, and every time PHP starts, it is not created from scratch, but is restored to its previous state.