CodeIgniter Forums
Codeigniter basics - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21)
+--- Thread: Codeigniter basics (/showthread.php?tid=40196)



Codeigniter basics - El Forum - 04-01-2011

[eluser]mahmood rehman[/eluser]
Can someone tell me why we use $this.
if it is for current object than what it mean $this->load->view();
in the load function what $this do ?


Codeigniter basics - El Forum - 04-01-2011

[eluser]InsiteFX[/eluser]
The Basics

InsiteFX


Codeigniter basics - El Forum - 04-01-2011

[eluser]mahmood rehman[/eluser]
i cant understand what u mean sorry for that i want only that when we load view in codeigniter using $this->load->view('somthing');
what does $this means here ?


Codeigniter basics - El Forum - 04-01-2011

[eluser]InsiteFX[/eluser]
The pseudo-variable $this is available when a method is called from within an object context. $this is a reference to the calling object (usually the object to which the method belongs, but possibly another object, if the method is called statically from the context of a secondary object).

So if your in your controller $this is pointing to your controller class object.

$this is referring to the class you are in.

InsiteFX


Codeigniter basics - El Forum - 06-24-2012

[eluser]arunoda[/eluser]
Here is a place you should look for codeigniter basics

1. http://www.udemy.com/codeigniter-learn-it-correct/
2. http://www.youtube.com/watch?v=aOtDzuyBqqM&list=PLA81C68F3BB3AE307