Add Me!Close Menu Navigation

PHP | Web Development | Object Oriented | MVC | MySQL | Apache

Add Me!Open Categories Menu

Currently Browsing

Posts Tagged ‘ reference ’

17 December
Posted in PHP Coding

References and object access in PHP

Reading some code this morning I realised that some people use overcomplicated object access syntax. In OOP, some objects can be deep in the structure. Calling their methods or accessing their attributes involves long lines and hard to read code as shown bellow. <?php $fu1 = $someobject->otherone->yetanother->lastone->bar( 1 ); $fu2 [...]

Tag Cloud

Categories

Archive

Pages

Popular Posts