[eluser]RedFin[/eluser]
Hello CI-Coders,
I'm not native english and i'm pretty bad in describing problems, but i try my best.
I have a very common question about using the MVC to handle jQuery/Ajax requests.
This is my problem:
TabX | TabY | TabZ
ContentX|ContentY|ContentZ
I have a site with different Tabs which have different contents in it. However, i do not want to pre-load all of the content and use #tab.show()/hide(), since the content is pretty heavy and needs some time to load. For example: one content can need up to 2 seconds to load. I have like 5-6 tabs and this can easily need up to 10 seconds loading time.
My solution (not MVC) works like this: if i click a tab, i load the needed php-file via load() and show that file in the content area. all the database actions are inside this php file.
So now i need a solution how to fit this into the mvc pattern. What is the workflow around that? Can i load ControllerY to get the data of ModelY to parse it into ViewY when i click on TabY without reloading the page?
If this doesnt work at all, how would you solve this to have a nice and clean solution?
Kind regards,
John.