首次发帖在这里热爱网站。
所以我开始使用CodeIgniter,并希望将acl添加到我的网站。 搜索和阅读了很多,并决定与坦克认证。
使用: codeigniter 2.1.4
tank auth master
IIS
下载所有运行连接到数据库的脚本,没有任何内容......
我无法查看view / auth文件夹中的register_form.php
或任何视图,我得到的只是一个空白页面没有错误或任何内容。我认为路由有问题我尝试了100种不同的东西,并且无法在空白页面旁边得到任何东西。
任何想法如何解决这个问题?
非常感谢你的帮助。
$route['default_controller'] = 'auth/view';
$route['404_override'] = '';
编辑: 到目前为止我还有什么......
所以我改变了这条路线: $ route ['default_controller'] ='auth / login'; $ route ['404_override'] ='';
启用所有日志记录无显示
确保我处于开发模式 仍然没有空白页
修改 的
so sloved the problem it was with the database load ($this->ci->load->database();)
no error were showen only thing in log of CI was (Database Driver Class Initialized)
problem was that php 5.5 doesnt come enable , need to enable it.
locate the php.ini (cmd->run c:\php\php.exe --ini for location)
edit the next stuff in file:
extension=php_mysql.dll
extension=php_mysqli.dll
extension_dir = "C:\PHP\ext"
then make sure that in apachee httd.conf u have it ponted to the location of the right php.ini
PHPIniDir "C:\php\PHP.ini"
hopes this help some one in the future :)
答案 0 :(得分:0)
$route['default_controller'] = 'auth/login'; //there is no such method in auth like you are suggesting
这会让你直接登录!制作锚点以进行身份验证/注册以查看注册视图。
答案 1 :(得分:0)
我认为,有些事情是错误的,我想没有人想让默认控制器登录。 (所以你遇到了无法打开身份验证/注册或登录而你想通过路由解决的问题)
我正在使用tank_auth。从未改变路线设置。 确保配置文件,库,模型在那里,我建议你打开error_reporting来获取所有警告。
打开索引php,将此代码添加到第38行。
case 'development':
error_reporting(E_ALL ^ (E_NOTICE));
break;
答案 2 :(得分:0)
($this->ci->load->database();)
no error were showen only thing in log of CI was (Database Driver Class Initialized)
problem was that php 5.5 doesnt come enable , need to enable it.
locate the php.ini (cmd->run c:\php\php.exe --ini for location)
edit the next stuff in file:
extension=php_mysql.dll
extension=php_mysqli.dll
extension_dir = "C:\PHP\ext"
then make sure that in apachee httd.conf u have it ponted to the location of the right php.ini
PHPIniDir "C:\php\PHP.ini"
希望这有助于将来某人:)