School site with multiple sub schools |
[eluser]clip[/eluser]
[quote author="yabune" date="1256348015"]Hi, I'm new to CI, but I really like the way to use it, so I'm trying to apply it to a site, but I have some questions about the proper use of CI in this situation. It's a site for a school that is divided in two schools. The site is the same for the two schools (same template), but some contents is different for each school. So I have, for example: http://www.schoolsite.com/school1 http://www.schoolsite.com/school1/news http://www.schoolsite.com/school1/classes http://www.schoolsite.com/school2 http://www.schoolsite.com/school2/news http://www.schoolsite.com/school2/classes What should be the best way to program this? Should I create 2 folders (school1 and school2) and put inside each one the classes I need? But I would like to use the same controllers for each school (so I don't have to repeat code), the difference would be the news (for example) to be specific to that school. Maybe I should create a model for the news. But would I have to create two news controller classes inside each folder to call this model? Thank you![/quote] Maybe you could utilize the $this->uri->uri_to_assoc(n) from the URI Class |
Messages In This Thread |
School site with multiple sub schools - by El Forum - 10-23-2009, 02:33 PM
School site with multiple sub schools - by El Forum - 10-23-2009, 02:39 PM
School site with multiple sub schools - by El Forum - 10-23-2009, 02:52 PM
School site with multiple sub schools - by El Forum - 10-23-2009, 03:05 PM
School site with multiple sub schools - by El Forum - 10-23-2009, 03:11 PM
|