load model in view.. - 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: load model in view.. (/showthread.php?tid=28788) |
load model in view.. - El Forum - 03-22-2010 [eluser]husni[/eluser] hey guys..can i load and use model in view file.. i dont have any idea to develop the codes in better way i guess.. load model in view.. - El Forum - 03-22-2010 [eluser]flaky[/eluser] Why would you load the model in the view? load model in view.. - El Forum - 03-22-2010 [eluser]Mareshal[/eluser] Why not load the model in the controller that's rendering the view? load model in view.. - El Forum - 03-22-2010 [eluser]husni[/eluser] [quote author="flaky" date="1269268013"]Why would you load the model in the view?[/quote] i got the moduleID in the view..i want to calculate somethings and need to carry the moduleID to the function in model in order to do the calculation.. can i do that? load model in view.. - El Forum - 03-22-2010 [eluser]husni[/eluser] [quote author="Mareshal" date="1269268259"]Why not load the model in the controller that's rendering the view?[/quote] i dont know how to do that because i load the model in the controller to get the array of modules and display all of the modules in view.. i want to do calculation for each module so i have load the model in view..can i do that? |