上一页 1 ··· 3 4 5 6 7 8 9 10 下一页
摘要: function download_file($url) { // $url = http://192.168.8.95/vm/download_file?downurl=http://192.168.8.96/download/test1.tar.gz; // 要下载的文件可能在本地,也可能在其他节点服务器 if (empty($url) || false === @f... 阅读全文
posted @ 2017-06-16 16:47 gentsir 阅读(3637) 评论(0) 推荐(0)
摘要: // jquery实现动态选中select var active = $('.all_sla_title1 .active') var group_name = active.html(); var sla = active.attr('data-sla'); var remote = active.attr('data-remote'); // console.log(group_name... 阅读全文
posted @ 2017-03-31 19:40 gentsir 阅读(3995) 评论(0) 推荐(0)
摘要: 1、yum -y update // 更新系统 1.1)yum -y install gcc g++ gcc-c++ make kernel-devel kernel-headers 1.2)vi /etc/selinux/config # 禁止SELINUX 1.3)设置SELINUX=disab 阅读全文
posted @ 2017-03-20 16:19 gentsir 阅读(658) 评论(0) 推荐(0)
摘要: 1. mysql -u root -p; // 登录mysql, 并输入密码 2. use mysql; // 打开 mysql 数据库 3. update user set host='%' where user='root' and host='localhost'; // 允许远程登录 upd 阅读全文
posted @ 2017-03-20 11:05 gentsir 阅读(2739) 评论(0) 推荐(0)
摘要: 1、一般的order by 语句其返回的结果为 2、这个很显然不是我想要的结果,修改SQL如下[红色为关键语句] 阅读全文
posted @ 2017-03-17 11:11 gentsir 阅读(2524) 评论(0) 推荐(1)
摘要: 1、die()是exit()的别名函数,用法与exit()完全相同,php手册上的说法是,“使用这种别名通常不是个好主意,因为这种别名可能会被完全废弃或更名,导致脚本难以移植到新版本的 PHP 上。” (http://php.net/manual/zh/aliases.php)。所以建议使用exit 阅读全文
posted @ 2017-03-10 16:38 gentsir 阅读(545) 评论(0) 推荐(0)
摘要: $z = date('Y-m'); $a = date('Y-m', strtotime('-12 months')); $begin = new DateTime($a); $end = new DateTime($z); $end = $end->modify('+1 month'); $int 阅读全文
posted @ 2017-03-09 11:10 gentsir 阅读(1633) 评论(0) 推荐(1)
摘要: /** * 无级递归分类 TP框架 * @param int $assortPid 要查询分类的父级id * @param mixed $tag 上下级分类之间的分隔符 * @return string $tree 返回的分类树型结构结果 * */ function recursiveAssort($assortPid,... 阅读全文
posted @ 2017-03-02 15:10 gentsir 阅读(461) 评论(0) 推荐(1)
摘要: 1 /** 2 * 把KB转化为KB及以上单位 3 * @param int $kb 4 * @return string $new_val 5 */ 6 function return_over_kb($kb) 7 { 8 $kb /= 1024; 9 $unit = 0; // 0KB/MB 1GB 2TB 3PB 4EB 10 w... 阅读全文
posted @ 2016-09-14 12:16 gentsir 阅读(675) 评论(0) 推荐(0)
摘要: 1、借鉴评论的方法[20170309 edit] 2、old方法 $last_month = date('Y-m', strtotime('last month')); $last['first'] = $last_month . '-01 00:00:00';$last['end'] = date 阅读全文
posted @ 2016-09-09 18:51 gentsir 阅读(2032) 评论(1) 推荐(0)
上一页 1 ··· 3 4 5 6 7 8 9 10 下一页