07 2017 档案

js弹出窗口小特效-PHP
摘要:var width=document.documentElement.clientWidth||document.body.clientWidth;var height=document.documentElement.clientHeight||document.body.clientHeight 阅读全文

posted @ 2017-07-26 10:57 夏霁 阅读(1568) 评论(0) 推荐(0)

读取Excel文件成数组-PHP
摘要:<?phprequire('PHPExcel/Classes/PHPExcel.php');//引入PHP EXCEL类function format_excel2array($filePath='',$sheet=0){ if(empty($filePath) or !file_exists($f 阅读全文

posted @ 2017-07-26 10:56 夏霁 阅读(2533) 评论(0) 推荐(0)

美化文件上传按钮-PHP
摘要:<style type="text/css"> .a-upload { padding: 4px 10px; height: 20px; line-height: 20px; position: relative; cursor: pointer; color: #888; background: 阅读全文

posted @ 2017-07-26 10:54 夏霁 阅读(479) 评论(0) 推荐(0)

获取文件后缀名并命名新文件名防止重复-php
摘要:$FileName = $file['name'];//获取上传的文件名$Extension = substr($FileName, (strrpos($sFileName, '.') + 1));//找到扩展名$Extension = strtolower($Extension);$FileNam 阅读全文

posted @ 2017-07-14 16:59 夏霁 阅读(846) 评论(0) 推荐(0)

分页类及调用-PHP
摘要:<?phpclass PageClass{private $myde_count; //总记录数public $myde_size; //每页记录数private $myde_page; //当前页private $myde_page_count; //总页数private $page_url; / 阅读全文

posted @ 2017-07-13 15:53 夏霁 阅读(177) 评论(0) 推荐(0)

上传图片并生成相关缩略图-PHP
摘要:if(!empty($_FILES["fileField"]["name"])){//检测表单传递文件数据 $fileinfo = $_FILES["fileField"]; if($fileinfo['size'] < 10000000 && $fileinfo['size'] > 0){//大小 阅读全文

posted @ 2017-07-13 15:47 夏霁 阅读(500) 评论(0) 推荐(0)