-
2020-08-06 09:45:03
- PHP基于curl post实现发送url中文乱码怎么办
- PHP基于curl post实现发送url中文乱码的解决办法:首先确认网址编码;然后使用curl需要加header设置charset,代码为【$this_header = array(“charset=UTF-8”)】。
-
4135
-
2020-08-06 09:53:30
- php删除文件代码是什么
- php删除文件代码:首先设置参数来删除文件路径,代码为【$path2= "./upload/picture/"】;然后使用公共方法删除,代码为【public function delDirAndFile($path, $delDir= 】。
-
3276
-
2020-08-06 10:03:15
- ci如何隐藏index.php
- ci隐藏index.php的方法:首先打开【rewrite_module】,并修改AllowOverride none为AllowOverride All;然后在CI的目录下面创建【.htaccess】文件并添加相关内容;最后相关内容即可。
-
2242
-
2020-08-06 10:11:28
- php如何查询文件是否存在
- php查询文件是否存在的方法:使用自带的函数【file_exists】判断文件是否存在,代码为【if(file_exists($file)){echo "当前目录中,文件".$file."存在"}】。
-
8066
-
2020-08-06 10:19:48
- php下redis设置密码问题
- php下redis设置密码的方法:首先打开【/path/to/redis.conf】,修改requirepass后的密码;然后重启redis服务;最后运行显示结果即可。
-
2985
-
2020-08-06 10:42:04
- php中文编码转换问题
- php中文编码转换的方法:1、使用iconv函数,代码为【string iconv (string $in_, string $out_, string $str)】;2、使用【mb_convert_encoding】函数。
-
2326
-
2020-08-06 10:48:35
- php下nginx 500错误怎么办
- php下nginx 500错误的解决办法:首先打开【limits.conf】文件,加入相关代码;然后在【worker_processes】后加入一行语句;最后重新启动nginx,重新载入设置即可。
-
4232
-
2020-08-06 11:18:27
- php如何更改文件权限
- php更改文件权限的方法:使用函数【chmod】将filename所指定文件的模式改成mode所给定的,代码为【chmod ( string $filename , int $mode ) : bool】。
-
2731
-
2020-08-06 11:36:26
- PHP获取当前页面的最后修改时间问题
- PHP获取当前页面的最后修改时间的方法:使用【date()】函数格式化本地时间或日期,使用【getlastmod()】函数获取页面最后修改的时间,代码为【getlastmod( void ):int】。
-
2150
-
2020-08-06 11:45:11
- PHP+MYSQL中文乱码怎么办
- PHP+MYSQL中文乱码的解决办法:首先在建表的时候设置编码类型为【gb2312_chinese_ci】;然后在php页面的数据库连接语句加相关语句,代码为【mysql_query("SET NAMES'gb2312'",$link)】。
-
2424