摘要:因为在开发内部BI系统中需要画出统计图表,我选了Jpgraph 开源绘图工具实现需求。之前实现过需求,没想到这次又花了很多时间回忆,各种搜索,真的是好记性不如烂笔头,不会总结的人没有未来啊。常用的三种图表样式:|———— 3D饼图:include ("jpgraph/jpgraph.php");include ("jpgraph/jpgraph_pie.php");include ("jpgraph/jpgraph_pie3d.php");$data = array(218,100);$datatitle = array('男
阅读全文
摘要:便于记忆 这里写一个PHPexcel导出的demo我们构造一个数据 $letter = array('A','B','D','E'); //sheet索引 $date = array( array( 'ID', '姓名', '性别', '职务' ), array( 12, ...
阅读全文
摘要:/** * Class Interval * @author logonmy * @desc 简单分析程序执行时间; */Class Interval{ var $start; public function getTrueTime() { list($sec,$unix) = explode(' ',microtime()); return (float)$unix+(float)$sec; } public function __construct() { $this->start = $this->getTr...
阅读全文
摘要:认识一:当我们需要更改session生存时间的时候通行的做法是更改php.ini文件中 1: ; Name of the session (used as cookie name). 2: session.name = PHPSESSID 3: 4: ; Initialize session on request startup. 5: session.auto_start = 0 6: 7: ; Lifetime in seconds of cookie or, if 0, until browser is restarted. 8: se...
阅读全文
摘要:比较实用的debug方法:具体参考地址已经记不清了,这里重写成类方便调用/** * @author logonmy@126.com * @Date: 13-7-23 * @desc example to count application run time */class Interval{ var $start; public function getTrueTime() { list($sec,$unix) = explode(' ',microtime()); return (float)$unix+(float)$sec; } ...
阅读全文