![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
php
氵猿木木灬
这个作者很懒,什么都没留下…
展开
-
PHP 5.3低版本使用array_chunk,array_multisort
array_chunk() 把一个数组分割为新的数组块。function array_val_chunk($array){ $result = array(); foreach ($array as $key => $value) { $result[$value[1].$value['is_ev']][] = $value; } $ret = array(); //这里把简直转成了数字的,方便.原创 2022-01-20 10:16:29 · 297 阅读 · 0 评论 -
通过域名获取IP地址
<?php/*** 使用PHP检测能否ping通IP或域名* @param type $address* @return boolean*/function pingAddress($address) {$status = -1;if (strcasecmp(PHP_OS, 'WINNT') === 0) {// Windows 服务器下$pingresult = exec("ping -n 1 {$address}", $...转载 2021-12-27 15:25:22 · 909 阅读 · 0 评论 -
阿里云虚拟主机项目根目录指向public目录下
在根目录下新建.htaccess文件,内容如下<IfModule mod_rewrite.c>RewriteEngine onRewriteBase / RewriteCond %{REQUEST_URI} !^/public/ RewriteRule ^(.*)$ public/$1?Rewrite [L,QSA]</IfModule>至此即可以完成指向,无需改动文件。ftp上传之后可能看不到文件,是因为....原创 2021-04-20 13:28:58 · 940 阅读 · 0 评论 -
PHP executable not found. Install PHP 7 and add it to your PATH or set the php.executablePath s
{ "php.validate.executablePath":"D:/wamp/bin/php/php7.0.10/php.exe", "php.executablePath":"D:/wamp/bin/php/php7.0.10/php.exe" }原创 2021-04-20 13:26:08 · 1138 阅读 · 0 评论 -
2020年最新PHP面试题汇总(附答案)
2020年最新PHP面试题汇总(附答案)1.请自我介绍一下?答:我叫xxx,来自北京,20xx年毕业于xx大学计算机xx系,毕业后在武汉从事了x年的php开发工作,公司是一个外包公司,主要做微信开发,公众号推广,商城,论坛的开发2.你在公司负责那些项目?答:由于我们公司是一个外包公司,不可能只做一个项目,公司的项目都是交叉进行的,论坛,微信,商城我都做过?3.你为什么来深圳?答:因为我哥在这边,父母也希望兄弟间有个照应,而且深圳是一线城市,技术也比广西前沿一些4.武汉使用什么前端框架和后端框转载 2020-12-10 13:15:21 · 27664 阅读 · 0 评论 -
微信小程序登录-PHP后端
微信小程序登录以及获取openid(用户唯一标识)和session_key一、前端登录代码://登录获取codelogin:function(){wx.login({success:function(res){console.log(res.code)//发送请求wx.request({url:'填写你的后端接口地址',//接口地址data:{code:res...转载 2020-12-10 13:24:49 · 551 阅读 · 0 评论 -
微信小程序支付-PHP后端
1.先写一个可以点击支付的按钮<viewclass="chongzhi_button"bindtap="pay">支付</view>2.开始js代码pay:function(){//下订单并唤起微信支付varprice='0.01';//支付金额varopenid='';//这里传用户openid,怎么获取用户的openid这里就不详细的说了varthat=this;wx.reques...转载 2020-12-10 13:22:38 · 543 阅读 · 0 评论