Why we used $this->set() in cakePHP?

It is used for creating a variable in the view file with $this->set('variable1','bestinterviewquestion.com'); in controller fie and then that variable $variable1 will be available to use in the view template file for that action.

Suggest An Answer

No suggestions avaliable!

Latest post from CakePHP interview questions

Ask Question