简体   繁体   English

XAMPP在codeigniter上加载空白屏幕

[英]XAMPP load blank screen on codeigniter

I'm using XAMPP as my localhost server testing, and I'm using the CodeIgniter PHP framework for my web app. 我正在使用XAMPP作为我的本地主机服务器测试,我正在使用CodeIgniter PHP框架作为我的Web应用程序。

When I want to test my web application, XAMPP doesn't load properly. 当我想测试我的Web应用程序时,XAMPP无法正确加载。 I've been waiting around a minute, and then what I get is just blank screen on the browser page. 我已经等了大约一分钟,然后我得到的只是浏览器页面上的空白屏幕。

I really need a local testing. 我真的需要本地测试。 But, oddly my CodeIgniter does work very well on my web hosting; 但是,奇怪的是我的CodeIgniter在我的网络托管上工作得很好; no errors at all. 没有任何错误。

I'm using XAMPP v3.2.1, and my PHP version is 5.6.3. 我正在使用XAMPP v3.2.1,我的PHP版本是5.6.3。

Is there any custom configuration I should do? 我应该做任何自定义配置吗?

And one more thing: this blank screen only appears when the model is trying to fetch data from database. 还有一件事:只有当模型试图从数据库中获取数据时才会出现此空白屏幕。

I have tested things like "Hello world" and it works fine. 我测试了“Hello world”之类的东西,它运行正常。 Any ideas? 有任何想法吗?

Because 因为
* Your XAMPP works (because HelloWord program run correctly) *你的XAMPP有效(因为HelloWord程序运行正常)
* Your web application on real server works. *您的真实服务器上的Web应用程序工作。

You check your routing configuration . 您检查路由配置

See more: https://ellislab.com/codeIgniter/user-guide/general/routing.html 查看更多: https//ellislab.com/codeIgniter/user-guide/general/routing.html
(Try checking HTML source from blank page what you have seen, try enter url domain_at_localhost/[controler]/[action]/[param1]/[param2]... manually, and see result.) (尝试从空白页检查HTML源代码,尝试输入url domain_at_localhost / [controler] / [action] / [param1] / [param2] ...手动,并查看结果。)

Blank page is likely due to PHP errors with directives to display errors turned off. 空白页可能是由于PHP错误导致显示错误的指令被关闭。 Check your php.ini for display_errors , html_errors and error_reporting directives. 检查你的php.ini上的display_errorshtml_errorserror_reporting指令。 Should be: 应该:

display_errors = On
html_errors = On
error_reporting = E_ALL & ~E_DEPRECATED & ~E_STRICT

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM