-
基于win2003虚拟机中apache服务器的访问
[PHP教程] 2021-02-24 03:45:55 50人阅读
虽然在win2003配置PHP有点非主流,但你还是要会怎么弄。你也可以将本文的虚拟机看成是服务器,宿主机看成是客户端。 不像Linux系统,由于win2003有IIS的存在,占有了固有的80的端口,在win2003虚拟机中配置的apache...[详细]
-
php7安装mongoDB扩展的方法分析
[PHP教程] 2021-02-24 03:45:16 75人阅读
本文讲述了php7安装mongoDB扩展的方法。供大家参考研究具体如下: 这里我们使用pecl命令来安装 首先来到php7的安装目录 回车,执行成功后,会输出以下结果: 接下来我们需要打开php.ini文件,添加extension=mongodb....[详细]
-
PHP编程获取图片的主色调的方法【基于Imagick扩
[PHP教程] 2021-02-24 03:44:29 193人阅读
本篇章节讲解PHP编程获取图片的主色调的方法。供大家参考研究具体如下: 代码中用到了php的图片扩展,所以使用之前,需要先安装PHP的Imagick扩展,具体安装如下(window下): 代码如下: quantizeImage( 10,Imagick:...[详细]
-
YII框架中使用memcache的方法详解
[PHP教程] 2021-02-24 03:33:10 136人阅读
本篇章节讲解YII框架中使用memcache的方法。供大家参考研究具体如下: yii中可以很方便的使用memcache 一.配置 在main.php的components中加入cache配置 array( 'cache...[详细]
-
Yii 2.0实现联表查询加搜索分页的方法示例
[PHP教程] 2021-02-24 03:32:05 96人阅读
前言 最近在学习yii2.0,在使用yii2.0过程中遇到一些问题,现将查询搜索分页的方法整理如下,分享出来供大家参考学习,话不多说,来一起看看详细的介绍: 主表:{{%article}} 关联表:{{%article_class}} 方法如下 1...[详细]
-
利用php操作memcache缓存的基础方法示例
[PHP教程] 2021-02-24 03:31:23 198人阅读
前言 最近在工作中又遇到了memcache,大家应该都有所了解,memcache 是一个高效的分布式的内存对象缓存系统,他可以支持把php的各种数据(数组,对象,基本数据类型)放在它管理的内存中,本文将给大家详细介绍关于p...[详细]
-
PHP实现的简单在线计算器功能示例
[PHP教程] 2021-02-24 03:30:44 120人阅读
本篇章节讲解PHP实现的简单在线计算器功能。供大家参考研究具体如下: 简单的计算器(www.jb51.cc) 第一个操作数不能为空 ";unset($_POST["sub"]);//取消表单中的提交变量,后面计算判断时将不执行}if(empty($_POST["...[详细]
-
yii2学习教程之5种内置行为类详解
[PHP教程] 2021-02-24 03:16:46 117人阅读
前言 众所周知学习所有知识都需要循序渐进,行为也是一样,在我们学会很牛逼的新建行为,然后轻松注入到组件类之前,先看看yii2框架为我们准备的5个内置的行为类,也许你刚要用到~话不多说了,来一起看看详细的介绍...[详细]
-
Yii2使用表单上传文件的实例代码
[PHP教程] 2021-02-24 03:16:08 77人阅读
yii2用表单上传文件经常用到的,该怎样上传呢? 1、单个文件上传 首先建立一个模型models/UploadForm.php,内容如下 use yii\base\Model; use yii\web\UploadedFile; /** UploadForm is the model behind the upload ...[详细]
-
Yii 2中的load()和save()示例详解
[PHP教程] 2021-02-24 02:45:30 96人阅读
前言 本文主要给大家介绍的是关于Yii2中load()和save()的相关内容,分享出来供大家参考学习,话不多说,来一起看看详细的介绍吧。 我这里用的数据库是mongo 数据库 为栗子: formName() : $formName; //调用load 一...[详细]
- 这篇文章主要介绍了Laravel 5.0 发布 新版本特性详解,...[详细]
- 计算两个日期之间的时间差需要先把两个日期转换成纪元...[详细]
- 初步使用面向对象程序设计,要掌握的就是使用面向对象...[详细]
- 每个 PHP 数组内部都有一个指针,该指针指向数组的某...[详细]
- 因为 PHP 是一个 Web 编程语言,在编程过程中难免会遇...[详细]
- PHP 中提供了 return 语句来返回函数的运行结果,其语...[详细]
- final 关键字的作用如下: 使用 final 修饰的类,不能...[详细]
- 在使用 switch 语句时应该注意以下几点: 和 if 语句...[详细]
- 这篇文章主要给大家介绍了关于PHP替换Word中变量并导...[详细]
- 这篇文章主要介绍了PHP常量DIRECTORY_SEPARATOR原理及...[详细]