05 2014 档案

摘要:linux 中的定时任务crontab使用方法: 切换到root用户,sudo su root (可以设置成不需要输入密码) sudo su - (需要输入当前帐号的密码才能进入。) crontab -e 进入编辑界面,i进入编辑状态,esc键返回,:wq保存退出。 01 * * * * root run-parts /etc/cron.hourly 02 4 * * * root run-parts /etc/cron.daily 22 4 * * 0 root run-parts /etc/cron.weekly 42 4 1 * * root run-parts /etc/cron.monthly 阅读全文
posted @ 2014-05-30 13:27 大自然的流风 阅读(914) 评论(0) 推荐(0) 编辑
摘要:linux查看是否有某个运行的进程命令:例如,查询是否包含 “my_post” 关键字的进程 ps aux | grep my_post ps aux | grep my_post | grep -v grep root 3682 0.0 0.3 76068 3192 ? S 13:00 0:00 curl -s http://www.cnblogs.com/zdz8207/ 注:grep -v grep 是不显示grep查询这个进程 阅读全文
posted @ 2014-05-30 13:20 大自然的流风 阅读(32010) 评论(0) 推荐(0) 编辑
摘要:Maximum execution time of 30 seconds exceeded解决错误方法 Fatal error: Maximum execution time of 30 seconds exceeded 出现这个错误如何解决 去哪里可以设置最大执行时间 办法: 修改php.ini: max_execution_time = 300 ,秒可以设置更大,然后重起服务 或者在程序写 set_time_limit(时间) //0为无限制 阅读全文
posted @ 2014-05-23 15:17 大自然的流风 阅读(3731) 评论(0) 推荐(0) 编辑
摘要:php 获取随机数的几个方式 1.直接获取从min-max的数,例如1-20:$randnum = mt_rand(1, 20); 2.在一个数组里面随机选择一个(验证码的时候需要字母、数字混合的情况) 阅读全文
posted @ 2014-05-22 17:37 大自然的流风 阅读(2145) 评论(0) 推荐(0) 编辑
摘要:php header utf8 插入header("Content-type: text/html; charset=utf-8"); 阅读全文
posted @ 2014-05-22 14:29 大自然的流风 阅读(60901) 评论(1) 推荐(1) 编辑
摘要:php mysqli query 查询数据库后读取内容的方法 阅读全文
posted @ 2014-05-22 13:50 大自然的流风 阅读(51423) 评论(0) 推荐(1) 编辑
摘要:win7 xampp 验证码,session出不来的问题 需要在前面加上全路径,如:"\xampp\tmp" 变成"D:\xampp\tmp" 阅读全文
posted @ 2014-05-22 12:25 大自然的流风 阅读(1534) 评论(0) 推荐(0) 编辑
摘要:apache 中 ServerAlias让多个域名绑定到同一空间 在apache的虚拟主机中,如果书写了。ServerAlias www.a2.com www.a3.com这样的语句,就可以给虚拟主机增加多个域名,而且这些域名都访问同一个站点。 让a1,a2,a3 三个域名都访问到同一个空间。 阅读全文
posted @ 2014-05-21 20:40 大自然的流风 阅读(637) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示