在使用php程序时提示Warning: touch() [function.touch]:Utime failed:Permission denied in错误,下面一起来看看此问题的解决办法.

使用timthumb.php出现Warning: touch() [function.touch]: Utime failed: Permission denied in错误.

我们先来看一下touch()函数例子,touch() 函数设置指定文件的访问和修改时间.

touch(filename,time,atime)

例子,代码如下:

应用例子时出现错误:用timthumb.php来做缩略图,本地测试很OK,但是放到vps上面就出现下面的错误错误提示:

Warning: touch() [function.touch]: Utime failed: Permission denied in /home/wordpress/wp-content/themes/zkeyword/library/timthumb.php on line 199

A TimThumb error has occured

The following error(s) occured:Could note create the index.html file - to fix this create an empty file named index.html file in the cache directory.

从字面上理解,是创建缓存的cache文件没有权限,我就直接将cache的权限设为0777,但是还是不行,还是提示权限不足,进入cache目录后还有一个index.html文件,将其设为0777,问题就解决了(责任编辑:最模板)

php utime,php提示 Warning: touch() [function.touch]: Utime failed: Pe相关推荐

  1. php touch 无效,php提示 Warning: touch() [function.touch]: Utime failed: Permission denied in错误...

    在使用php程序时提示Warning: touch() [function.touch]: Utime failed: Permission denied in错误,下面一起来看看此问题的解决办法. ...

  2. Warning: touch() [function.touch]: Utime failed: Permission denied in /home/wordpress/wp-content/the

    原因: 对应文件所在文件夹的权限不够,需要赋权0777 处理: 创建缓存的cache文件没有权限,我就直接将cache的权限设为0777,但是还是不行,还是提示权限不足,进入cache目录后还有一个i ...

  3. PHP错误:Warning: preg_replace() [function.preg-replace]: Unknown modifier '[' in

    遇到一个PHP错误,错误提示是 Warning: preg_replace() [function.preg-replace]: Unknown modifier '[' in  .... , 当然了 ...

  4. docker部署rabbitmq出错touch: cannot touch ‘/etc/rabbitmq/rabbitmq.conf‘: Permission denied

    docker部署rabbitmq出错touch: cannot touch '/etc/rabbitmq/rabbitmq.conf': Permission denied 首先拉取镜像,这里我使用d ...

  5. php提示Warning:mysql_fetch_array() expects的解决方法

    本文实例讲述了php提示Warning mysql_fetch_array() expects的解决方法,分享给大家供大家参考.具体分析如下: 在mysql数据库连接时碰到Warning: mysql ...

  6. IAR for msp430 MDK中 warning: #223-D: function xxx declared implicitly 解决方法

    今天在EINT的范例里添加了一个函数,即eint.c中添加了一个datawrite()的函数,并在主函数main.c中调用,编译便警告 warning: #223-D: function " ...

  7. PHP调试的时候遇到Warning: session_start() [function.session-

    今天调试PHP的时候,PHP调试的时候遇到Warning: session_start() [function.session-start]: Cannot send session cache li ...

  8. php war,PHP提示Warning:phpinfo() has been disabled函数禁用的解决方法

    本文实例讲述了PHP提示Warning:phpinfo() has been disabled函数禁用的解决方法.分享给大家供大家参考.具体分析如下: 今天在一朋友服务器测试一个网站时发现我在测试ph ...

  9. touch: cannot touch /usr/local/tomcat/logs/catalina.out: Permission denied解决方法

    一.报以下错误: Using CATALINA_BASE: /home/apache-tomcat-7.0.72 Using CATALINA_HOME: /home/apache-tomcat-7. ...

最新文章

  1. 2020年“内容、服务”征集
  2. 关于Android中工作者线程的思考
  3. openfalcon 组件监控_open-falcon监控业务URL探测
  4. mysql如果数据不存在,则插入新数据,否则更新
  5. 6 四大组件之Service
  6. 阿里云sql监控配置-druid
  7. 向上2021·新消费品牌发展报告
  8. 如何通过大华sdk采集一帧图像?_EasyData解放数据标注员双手,采集清洗标注一站搞定...
  9. 富士康已看到芯片短缺开始缓解迹象 预计下半年会有改善
  10. Android使用HttpURLConnection下载图片
  11. python与java前景-数据告诉你,Python、Java、C+哪个更有发展前途?
  12. c语言取字节高四位低四位,C语言取一个数的最高位
  13. SCCM 2012系列13 操作系统播发②
  14. 通俗讲解比特币的原理及运作机制
  15. 小米AI音响的拆解及简要系统分析
  16. 快速pow算法c语言_c语言pow(c语言中用pow算法求)
  17. Linux内核延迟写机制学习
  18. 使用 kubeadm 初始化 worker节点出现 not ready 故障
  19. 民宿运营经验分享:玩转自我营销,带动流量持续增长
  20. hdu - 1435 Stable Match 稳定婚姻问题、Gale-Shapley算法模板

热门文章

  1. 创世对决怎么在电脑上玩 创世对决电脑版玩法攻略
  2. SpringMVC---狂神说Java学习笔记
  3. 芯片供应商如何看待国际十大芯片制作公司的排名
  4. matlab 保存原始图像,matlab原始图像都有哪些
  5. 编写一个函数,实现计算两个数大小的比较,且返回最大值。
  6. ios逆向工具Class-dump的安装和导出.h文件的教程
  7. 一级分类和二级分类的要点
  8. 冥王峡谷装linux教程,冥王峡谷黑苹果问题总结
  9. 职场 | 在职场中,有哪些习惯我们需要养成?
  10. 2021只剩10%了,分享一个关于单片机自学的秘密