dongshi1606 2011-05-03 00:52
浏览 37

CodeIgniter Web App +公共站点

I'm working on a project where the following are in development:

  • public info website with protected resource areas
  • web application

Both will be on the same server, under the same domain.

The web application is login protected. If a member logs into the web application, they can also access the protected resource areas on the public site and visa versa.

Q. Both are being developed using CodeIgniter. Because there is need for this shared login, is it advisable to keep both as one project/one big site structure? or 2 separate CI projects/structures with a means of sharing the login.

One developer is tackling the web app and one (me) is tackling the public site - so my feeling is that it would be easier to keep them separate structures with some cross-over for the login/session management.

  • 写回答

2条回答 默认 最新

  • douzhan6474 2011-05-03 01:44
    关注

    You might want to consider using a modular system and sharing resources. Codeigniter doesn't have built in modular support, but there are a few packages that will enable it. I've been using the Modular Extensions package for years, and can't imagine using CI without it.

    https://bitbucket.org/wiredesignz/codeigniter-modular-extensions-hmvc/wiki/Home

    You may be familiar with the concept already: Each module is basically it's own mini application. It follows the same structure you would see in the Codeigniter application folder. You can even have multiple module directories to separate your application structure even further.

    Any shared resources (libraries, helpers, etc) can stay in the default application directory, but if needed you can still cross-load them from other modules. Even if you were working alone, I still would recommend it because it really keeps things organized.

    Using modules, you can both work on the application independently, without stepping on each other's toes or even seeing any files that you aren't working with, while having access to the same shared resources (like your Login/Auth model), keeping things extremely organized, and without the hassle of creating two separate applications.

    评论

报告相同问题?

悬赏问题

  • ¥15 redis-full-check比较 两个集群的数据出错
  • ¥15 Matlab编程问题
  • ¥15 训练的多模态特征融合模型准确度很低怎么办
  • ¥15 kylin启动报错log4j类冲突
  • ¥15 超声波模块测距控制点灯,灯的闪烁很不稳定,经过调试发现测的距离偏大
  • ¥15 import arcpy出现importing _arcgisscripting 找不到相关程序
  • ¥15 onvif+openssl,vs2022编译openssl64
  • ¥15 iOS 自定义输入法-第三方输入法
  • ¥15 很想要一个很好的答案或提示
  • ¥15 扫描项目中发现AndroidOS.Agent、Android/SmsThief.LI!tr