2020年7月24日

php excel的使用

摘要: 1. 引入类 use PHPExcel; use PHPExcel_IOFactory; use PHPExcel_Reader_Excel5; use PHPExcel_Reader_Excel2007; use PHPExcel_RichText; 2导入 /** * PHPexcel导入 */ 阅读全文

posted @ 2020-07-24 13:48 vermouthmo 阅读(312) 评论(0) 推荐(0)

2020年7月20日

lave框架增删改查

摘要: 添加数据 // $arr=['type=>我的天']; // DB::table('book')->insert($arr); // // 添加后获取id // $id=DB::table('book')->insertGetId($arr); // var_dump($id); // // 更新 阅读全文

posted @ 2020-07-20 11:09 vermouthmo 阅读(159) 评论(0) 推荐(0)

2020年7月17日

laravel 框架

摘要: // 路由访问控制器方法 // Route::get('/','Intt@index'); //get方法 //Route::Post('/','Inttx@index'); //post方法 // 使用多个方法 //Route::match(['post','get'],'/','Intt@ind 阅读全文

posted @ 2020-07-17 16:57 vermouthmo 阅读(91) 评论(0) 推荐(0)

2020年7月7日

tp5控制器增删改查

摘要: // $data=['type'=>'专辑']; 构造数据 // db('book')->insert($data); 添加 // Db::name('book')->insert($data); // $userId = Db::name('book')->getLastInsID();添加主键i 阅读全文

posted @ 2020-07-07 16:57 vermouthmo 阅读(287) 评论(0) 推荐(0)

2020年7月6日

tp5控制器

摘要: namespace app\index\controller; use think\Controller; class Index extends Controller //继承父类 { //public function _initialize(){ //echo '初始化'; //初始化 pub 阅读全文

posted @ 2020-07-06 16:56 vermouthmo 阅读(132) 评论(0) 推荐(0)

2020年6月17日

php 类的继承

摘要: // 动物 父类 class anmials{ var $i='anm'; function aa(){ echo'动物'; } } // 猪 子类 class pig extends anmials{ var $p='zhu'; function aa(){ echo '猪八戒'; // 方法重写 阅读全文

posted @ 2020-06-17 09:42 vermouthmo 阅读(144) 评论(0) 推荐(0)

2020年6月16日

php文件加载

摘要: 1、require require_once跟require的区别是会检查文件是否已经被包含过,如果是则不会再次被包含; 2、include include_once跟include的区别是会检查文件是否已经被包含过,如果是则不会再次被包含; 运用在某几个页面,抬头结尾都一样的 时候 阅读全文

posted @ 2020-06-16 09:47 vermouthmo 阅读(118) 评论(0) 推荐(0)

php时间函数

摘要: 1: 设置时区:date_default_timezone_set('Asia/ShangHai'); 2: 时间函数 date() date ( string $format [, int $timestamp ] ) format:必需。规定时间的格式。Y-m-d H:i:s; 3.时间函数 t 阅读全文

posted @ 2020-06-16 09:44 vermouthmo 阅读(391) 评论(0) 推荐(0)

2020年6月12日

php&mysql的数据删除 ajax

摘要: php中的删除 php代码 $('.del').click(function(){ var id = $(this).data('id'); var that = $(this); layer.confirm('确定删除' + id + '吗?', { icon: 3, title: '提示' }, 阅读全文

posted @ 2020-06-12 09:23 vermouthmo 阅读(192) 评论(0) 推荐(0)

2020年6月10日

php&mysql的数据修改 layui的方法

摘要: 阅读全文

posted @ 2020-06-10 08:33 vermouthmo 阅读(414) 评论(0) 推荐(0)

导航