how to put other things in the $content ?

i wanna put something else inside the $content other than the default content… how do i do that?. Y_Y

You can edit the layouts/main.

You will find <?php echo $content?>, you can add whatever you want before and after it.

In $content there will be the content of the rendered view.

oh okay… what i was looking for actually was a way to add more info to the $content… only to know that $content’s content lies in the rendered view of the model :) my bad… we’ll my problem actually is one of my model’s contents doesn’t show it’s content in the $content… i mean even if i quote the $content in main.php it still shows… and it doesn’t follow the main layout and design. T_T

In content you will have ALL what you got with $this->render(), nothing more and nothing less.

Is a good mvc practice not to print/echo anything but what is in the view file (that is exaclty what a view is expectend to be).

If you have content that doesen’t follow this rule, maybe you are echoing this stuff in controller or in model with echo, that is not mvc, better not to do or you will not understand what is going on.

Also there are other layouts, column_1 and column_2, maybe your controller is using this other layout instead of the main one.

thank you very much!! i actually had column2 as default layout! thank you very much :D