0
votes
0answers
29 views

Writing Models in PyroCMS/Codeinighter Models

In Pyrocms there are Admin views and User views. Im developing a complex module where my model file is getting to be rather large. Should I be abstracting logic in my model files to also be User ...
0
votes
1answer
631 views

Slower Ajax Response

Does putting the view logic inside the controller increase page load speed? Because I have a controller action calling a view which I am loading through ajax and I am getting a very slow response. Why ...
0
votes
1answer
2k views

Making Class Diagram for MVC Pattern Project

I have a question about making a class diagram for an MVC based college senior project. If we have 2 actors of users in my system, lets say Undergrad and Graduate students are the children of ...
1
vote
2answers
168 views

Does a group of Select Statements count as a valid model?

I'm making a facebook app and I'm trying to follow MVC properly. But I was wondering if I had a class that was a bunch of fql queries (getting data from facebook) should I have keep these in a ...
0
votes
2answers
199 views

What is a good technique to prevent unauthenticated users from accessing controller methods?

I have an event(s) controller: class Event extends CI_Controller{ public function index(){ } public function foo(){ } //Shouldn't be able to use this method unless logged in ...
5
votes
2answers
1k views

Can REST API be used as business layer?

I am using PHP Codeigniter MVC design pattern and I had this project with some sort of specific business processes In my application I will be dealing with 2 existing REST APIs: Google Trello ...
4
votes
1answer
766 views

How to achieve N-Tier type in Codeigniter MVC [closed]

I know that N-Tier intended to separate layers on different network but I would like to have the same code separation in codeigniter I got this idea to have Model : for database CRUD - > Data layer ...
3
votes
2answers
1k views

Codeigniter/MVC workflow

Bit of a workflow question. I'm just staring with MVC and wondered how other people usually work in MVC? The 2 options I see is to code the model and controller completely first and then work on the ...
1
vote
1answer
99 views

Fitting an established site into a CI framework

I manage a rather large, feature full nightmare of a site which has no end of feature creep settings/options/etc. Up to now its been coded in a procedural/functional way and would like to move to an ...
1
vote
1answer
646 views

Performing user authentication in a CodeIgniter controller constructor?

In "The Clean Code Talks -- Unit Testing" (http://youtu.be/wEhu57pih5w), Miško Hevery mentions that "as little work as possible should be done in constructors [to make classes more easily testable]'. ...
5
votes
2answers
2k views

Models per database table?

I am using codeigniter, and have found myself in a similar situation where I have repeated Model methods. I am creating a Model per Controller. But I would creating a Model per database table be ...
4
votes
2answers
969 views

Controllers in CodeIgniter

I little bit new to the CodeIgniter framework and this is my first project with this framework. During a chat on StackOverflow somebody said that we need to make controllers tiny as possible. ...