Maison  >  Article  >  développement back-end  >  windosw改成centos后我的网站成白板了

windosw改成centos后我的网站成白板了

WBOY
WBOYoriginal
2016-06-23 13:42:541183parcourir

,网站是gb2312编码的windosw改成centos后我的网站成白板了。这是什么情况呢?在windows都很正常,换成centos就成白板了,也不报错。这是什么情况呢?下面是我网站的截图


回复讨论(解决方案)

这是为什么呢?怎么没有回答呢、??

首先你需要看下你的PHP版本,如果超出你写的代码支持的范围或者版本不够就会出现这种问题。

php.ini

display_errors= on

打开错误提示功能就知道是什么原因了。

display_errors= on已经设置了啊

$url = 'http://job.ncsq.net/index2.php';print_r(get_headers($url));


Array
(
    [0] => HTTP/1.1 200 OK
    [1] => Server: nginx/1.0.15
    [2] => Date: Mon, 15 Dec 2014 08:43:11 GMT
    [3] => Content-Type: text/html;charset=gb2312
    [4] => Connection: close
    [5] => X-Powered-By: PHP/5.2.17p1
    [6] => Set-Cookie:  PHPSESSID=af64987394c7dbfabbe917ee776cad46; path=/ sessionid 已发出,可认为程序并无严重的错误
    [7] => Expires: Thu, 19 Nov 1981 08:52:00 GMT
    [8] => Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
    [9] => Pragma: no-cache
    [10] =>  Content-Length: 0 文档流长度为 0,可能是因为某个条件不满足,程序直接退出了
)

看看是不是你某个编译目录没有执行权限

$url = 'http://job.ncsq.net/index2.php';print_r(get_headers($url));


Array
(
    [0] => HTTP/1.1 200 OK
    [1] => Server: nginx/1.0.15
    [2] => Date: Mon, 15 Dec 2014 08:43:11 GMT
    [3] => Content-Type: text/html;charset=gb2312
    [4] => Connection: close
    [5] => X-Powered-By: PHP/5.2.17p1
    [6] => Set-Cookie:  PHPSESSID=af64987394c7dbfabbe917ee776cad46; path=/ sessionid 已发出,可认为程序并无严重的错误
    [7] => Expires: Thu, 19 Nov 1981 08:52:00 GMT
    [8] => Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
    [9] => Pragma: no-cache
    [10] =>  Content-Length: 0 文档流长度为 0,可能是因为某个条件不满足,程序直接退出了
)


我是菜鸟啦 不懂的 是把这些代码复制进去吗?

出现问题就是白板

看看是不是你某个编译目录没有执行权限


我是php免费的开源程序 怎么知道他需要的权限呢?我觉得也是权限问题

看看你的程序文件夹是不是有rwx权限。

看看你的程序文件夹是不是有rwx权限。


有啊,是777权限呢
我是用的这个命令 chmod 777 -R 目录
Déclaration:
Le contenu de cet article est volontairement contribué par les internautes et les droits d'auteur appartiennent à l'auteur original. Ce site n'assume aucune responsabilité légale correspondante. Si vous trouvez un contenu suspecté de plagiat ou de contrefaçon, veuillez contacter admin@php.cn
Article précédent:PHP检测当前字符编码并转码Article suivant:PHP邮件扩展:mailpp