php session tmp 路径错误
星期一, 07. 20. 2009 – Category: 代码人生
PHP出现 Warning: session_start() [function.session-start]: open
Warning: session_start() [function.session-start]: open(/tmp\sess_84cb589ea249708b09c3d5e6836fdd0d, O_RDWR) failed: No such file or directory (2) in E:\web\htdocs\111.php on line 9
这个是session的tmp路径没有设置的缘故
你在php.ini(通常在C:\windows\ 目录下)的session.save_path设置一个路径就可以了,并且这个路径是有效的。比如:c:\winnt\temp
PhpMyAdmin 错误 “Cannot load mysql extension. Please check your PHP configuration”
星期五, 07. 17. 2009 – Category: 代码人生
Cannot load mysql extension. Please check your PHP configuration.
;extension=php_mysql.dll ==>> extension=php_mysql.dll
;extension=php_mysqli.dll ==>> extension=php_mysqli.dll
extension_dir “” ==>> extension_dir = “C:\Program Files\PHP”
Content of config.inc.php is:
<?
$cfg['Servers'][1]['host'] = ‘localhost’;
$cfg['Servers'][1]['extension'] = ‘mysql’;
$cfg['Servers'][1]['connect_type'] = ‘tcp’;
$cfg['Servers'][1]['compress'] = false;
$cfg['Servers'][1]['auth_type'] = ‘config’;
$cfg['Servers'][1]['user'] = ‘root’;
$cfg['Servers'][1]['password'] = ‘aaaa’;
?>
“Fatal error: Maximum execution time”
星期三, 07. 8. 2009 – Category: 代码人生
“Fatal error: Maximum execution time of 60 seconds exceeded in …”
这种错误大多出现在一些执行时间比较久的程序,例如循环、读取、上传等等(瞎写凑字数)。
大多原因在于 PHP 环境的PHP.ini 里的 max_execution_time 的设置,30,60,90….,但是有时候我们需要更长的时间,几小时,几十小时,总不可能都在这儿修改,况且大多空间是不让你改的。
这样最简便的方法就是在程序头加上这样一句:
set_time_limit(0);
不限制执行时间,OK,问题就算解决了!
Fatal error: Call to undefined function: stripos()
星期一, 05. 4. 2009 – Category: 代码人生
为什么会有这样的错误 “Fatal error: Call to undefined function: stripos()”?
查看了下手册:
stripos
(PHP 5)
stripos — Find position of first occurrence of a case-insensitive string
原来他是个PHP5作用的函数,但是网路上还是有很多服务空间是用的 php 4.3, 那么可以用下面的方法解决这个问题:
php代码出现错误分析详解
星期一, 05. 4. 2009 – Category: 代码人生
由于最近总是接触到php,经常会出现一些错误,特把php的常见的错误代码收集了下,希望对大家有帮助。
错误类型:
一、未使用二进制上传
代码:
Fatal error: This encoded file is corrupted. Please refer to http://www.zend.com/support/support_faq.php?id=loader_file_corrupt for further help in
/webhome/****.com/web/www/index.php on line 0
二、数据表中缺少字段
代码:
An error was encountered
Boka SiteEngine
数据库错误
错误信息1054: Unknown column ‘tuijian’ in ‘where clause’
出现错误的查询信息是
SELECT * FROM boka_product WHERE tuijian=1 AND classid IN (‘1′,’0′)ORDER BY id DESC LIMIT 4
三、服务器限制了网站使用内存的大小为8M,现在已经超过
代码:
Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 5898240 bytes)
四、这个是模板错误,header.php的529行所指出的模板,该模板的79行出错
[code]in [...]
关于站长
Google AD
最近文章
- Ubuntu 里 flash 中的汉字显示为框框
- CSS 层最小高度的全兼容写法
- Windows2k3配置PHP服务器环境
- Joomla TinyMCE 中文语言包
- JavaScript Runcode
- Lighttp Rewrite Rule For Wordpress
- IE8 里中英文字体高度不一样
- 南京夫子庙–瞻园一瞥
- 热烈庆祝本站PR荣升至5~~
- 走在乡间的小路上