need to understand

#1
[eluser]dang2man[/eluser]
hi guys
i am new in ci and i need to understand this portion
why and when i should use this method



function __construct(){
parent::__construct();
}

#2
[eluser]WanWizard[/eluser]
http://php.net/manual/en/language.oop5.decon.php

#3
[eluser]dang2man[/eluser]
i know how to use this method without ci

i want to know when i use __construct in ci

do i use this method when i load library or helper ?

#4
[eluser]WanWizard[/eluser]
When you do use a constructor? When you want to have something done when the class instance is constructed. When do you need to call the parent constructor? When your class extends another class that has a constructor.

There's nothing CI about it, it's a standard class constructor.

#5
[eluser]dang2man[/eluser]
thanks wan for your help


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.