php 开源项目汇总
摘要:WordPress是最热门的开源个人信息发布系统(Blog)之一,基于PHP+MySQL构建。WordPress提供的功能包括:1.文章发布、分类、归档。 2.提供文章、评论、分类等多种形式的RSS聚合。 3.提供链接的添加、归类功能。 4.支持评论的管理,垃圾信息过滤功能。 5.支持对样式CSS和
阅读全文
posted @
2018-06-08 11:10
程序猿的笔记
阅读(4596)
推荐(1)
php简单的数组递归
摘要:参照 http://www.oschina.net/code/snippet_105637_11401 的例子 $arr = array('aa' => array('bb' => array('id'=>5,'grade'=>5), 'cc' => array("name"=>'some'), '
阅读全文
posted @
2018-03-09 20:25
程序猿的笔记
阅读(758)
推荐(0)
合并两个数组 以KEY 作为键
摘要:<?php $a= array( array( 'ID'=> 2 ) ); $b= array( array( 'ID'=> 5656 ) ); print_r($r); //合并两个数组 以ID值 作为键 function mergeById(&$arr1,&$arr2, $key='ID') {
阅读全文
posted @
2018-03-09 20:18
程序猿的笔记
阅读(474)
推荐(0)
php curl 总结
摘要:1 curl post curl -X POST http://localhost/ -d '{"data":{"name":"hheh","shortname":"US"}}' -H "Content-Type: application/json" 2 curl: (5) Could not re
阅读全文
posted @
2017-11-30 10:12
程序猿的笔记
阅读(726)
推荐(0)
laravel-5-doctrine-2 教程
摘要:Open up a Terminal again, cd into learning folder and run: composer require "laravel-doctrine/orm:1.1.*" Likewise, install uuid-doctrine: composer req
阅读全文
posted @
2017-11-28 20:15
程序猿的笔记
阅读(689)
推荐(0)
Centos如何通过yum安装php7
摘要:执行如下命令安装epel yum -y install epel-release 执行如下命令安装epel yum -y install epel-release 更换rpm源,请根据自己的centos版本选择相应的rpm源进行安装 Centos 5.X: rpm -Uvh http://mirro
阅读全文
posted @
2017-09-28 16:22
程序猿的笔记
阅读(932)
推荐(0)
php 汉字转拼音函数
摘要:function Pinyin($_String, $_Code='UTF8'){ //GBK页面可改为gb2312,其他随意填写为UTF8 $_DataKey = "a|ai|an|ang|ao|ba|bai|ban|bang|bao|bei|ben|beng|bi|bian|biao|bie|b
阅读全文
posted @
2017-07-10 19:54
程序猿的笔记
阅读(555)
推荐(1)
使用CodeIgniter框架搭建RESTful API服务
摘要:https://blog.callmewhy.com/2014/07/12/restful-services-with-codeigniter/ http://www.php230.com/1412042281.html
阅读全文
posted @
2017-05-19 10:23
程序猿的笔记
阅读(1511)
推荐(0)
Session 失效原因
摘要:转载http://blog.csdn.net/LLorJJ999/article/details/4107464昨天去GTSC面试,有面试官问我关于Session丢失之后怎么查的问题,说老实话,开发到现在很少碰到这样的情况,唯一想到的就是Session超时,还有就是做Session读写日志,发觉面试...
阅读全文
posted @
2015-09-28 20:16
程序猿的笔记
阅读(1690)
推荐(0)
PHP实现把文本中的URL转换为链接的auolink()
摘要:转载:http://www.jb51.net/article/52916.htm其实我在《把文本中的URL地址转换为可点击链接的JavaScript、PHP自定义函数》一文中介绍过PHP代码如何实现将URL地址转化成链接的方法,今天给大家介绍一个更加简洁的版本,先来看看PHP的源代码:/*** Au...
阅读全文
posted @
2015-09-22 19:33
程序猿的笔记
阅读(1431)
推荐(0)
php关键词替换的类(避免重复替换,保留与还原原始链接)
摘要:转载:http://www.169it.com/blog_article/601549531.html本节主要内容:一个关键词替换的类主要可以用于关键词过滤,或关键词查找替换方面。实现过程分析:关键词替换,其实就是一个str_replace()的过程,如果是单纯的str_replace面对10W的关...
阅读全文
posted @
2015-09-21 14:37
程序猿的笔记
阅读(630)
推荐(0)
php 与 sql in 带参数
摘要:$arr[]IN ('.implode(', ', $arr).')
阅读全文
posted @
2015-06-29 19:01
程序猿的笔记
阅读(1513)
推荐(0)
php 日期计算 总结
摘要:1 加 2天date("Y-m-d", strtotime("$today + 2 days"));date("Y-m-d", strtotime("+ 2 days"));
阅读全文
posted @
2015-03-09 18:26
程序猿的笔记
阅读(445)
推荐(0)
使用 PHPMailer 发送邮件
摘要:转载http://blog.csdn.net/liruxing1715/article/details/7914974PHPMailer 的官方网站:http://phpmailer.worxware.com/PHPMailer 最新类库下载地址:【点击下载】PHPMailer GitHub 下载地...
阅读全文
posted @
2015-02-06 19:21
程序猿的笔记
阅读(429)
推荐(0)
生成uuid
摘要:function guid(){ if (function_exists('com_create_guid')){ return com_create_guid(); }else{ mt_srand((double)microtime()*10000);//optional for php 4....
阅读全文
posted @
2014-11-19 13:13
程序猿的笔记
阅读(824)
推荐(0)
PHPMailer不能发送邮件
摘要:PHPMailer不能连接SMTP服务器,和修改SMTP大小写没有关系(2011-10-22 12:17:35)转载▼标签:phpphpmailer杂谈分类:默认分类PHPmailer无法发送邮件,提示错误Error: Could not connect to SMTP host博客之前有两篇文章,...
阅读全文
posted @
2014-11-18 13:47
程序猿的笔记
阅读(2381)
推荐(0)
php array 分页
摘要:$array=array("1","2","3","4","5","6","7","8","9","10","11","12","13","14","15","16","17","18","19","20&qu
阅读全文
posted @
2014-09-17 17:14
程序猿的笔记
阅读(1760)
推荐(0)