该文被密码保护。 阅读全文
posted @ 2017-04-17 12:50 思念的色彩 阅读(0) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2017-04-17 12:48 思念的色彩 阅读(1) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2017-03-24 14:53 思念的色彩 阅读(2) 评论(0) 推荐(0) 编辑
摘要: <?php //冒泡排序 function maopao($arr){ $len=count($arr); for($i = 1;$i<$len;$i++)//循环控制冒泡排序的轮数 { for($k = 0;$k < $len-$i; $k++)//每轮冒出一个数需要比较的次数=元素数量-1 { 阅读全文
posted @ 2017-03-11 16:28 思念的色彩 阅读(85) 评论(0) 推荐(0) 编辑
摘要: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.or 阅读全文
posted @ 2017-03-06 17:06 思念的色彩 阅读(191) 评论(0) 推荐(0) 编辑
摘要: <?phpnamespace Home\Controller;use Think\Controller;class ShoppingcartController extends Controller { public function shoppingcart(){ if(IS_AJAX){ if( 阅读全文
posted @ 2017-03-06 17:03 思念的色彩 阅读(184) 评论(0) 推荐(0) 编辑
摘要: 1.$cid=empty($_GET['cid'])?16:$_GET['cid'];//判断传过来的cid, $count=M('news')->where('category_id='.$cid)->count();查询这个分类下的长度 $page=new \Think\Page($count, 阅读全文
posted @ 2017-03-06 15:09 思念的色彩 阅读(118) 评论(0) 推荐(0) 编辑
摘要: public function _initialize(){ $category=M('category');//实例化分类表 $contact=M('contact'); $about=M('about'); $contact=M('contact'); $lis=$contact->where( 阅读全文
posted @ 2017-03-06 14:55 思念的色彩 阅读(122) 评论(0) 推荐(0) 编辑
摘要: <?php/** * [vlogin 验证登录] */function vlogin(){ if(empty($_SESSION['alogin'])) //如果登录标识为空,表示未登录 { echo "<script>alert('请先登录!');window.location.href='ind 阅读全文
posted @ 2017-02-27 21:29 思念的色彩 阅读(205) 评论(0) 推荐(0) 编辑
摘要: <?php/** * [substrC 截取中文字符串] * @param [字符串] $data [要截取的字符串] * @param [自然数] $length [截取后长度] * @param [布尔值] $true [是否拼接...,默认为是] * @return [字符串] [截取后的字符 阅读全文
posted @ 2017-02-27 21:28 思念的色彩 阅读(148) 评论(0) 推荐(0) 编辑