array_multisort 使用示例

多维数组按字段多次排序$arr = array(); for ($i = 1;$i<10;$i++){ $item = array(); $item['name'] = 'name-' . $i; $item['number'] = rand(10,99); $item['sort'] = rand(1,10)[...]

JAVA AES SHA1PRNG 用PHP 实现

JAVA代码public static byte[] encrypt(String content, String password) throws Exception{ KeyGenerator kgen = KeyGenerator.getInstance("AES"); SecureRandom random [...]

gitee 使用webhook PHP 做代码自动部署

1、设置相关1.1、仓库使用ssh模式clone到本地1.2、仓库添加部署公钥2、服务器配置2.1、切换到PHP-FPM运行账户,无法切换时修改 /etc/passwd2.2、使用PHP-FPM运行账户生成gitee指定的公钥ssh-keygen -t ed25519 -C "[email protected]" 2.3、将公钥部署[...]

JS生成A标签自动跳转

const a = document.createElement('a')const url = body.data['fileUrl']a.href = urla.click()window.URL.revokeObjectURL(url)

ngx_http_limit_conn_module

使用版本 - CentOS Linux release 7.5.1804 (Core) - nginx/1.12.2版本 - curl 7.61.0 (x86_64-pc-linux-gnu) libcurl/7.61.0 OpenSSL/1.0.2k zlib/1.2.7 对于一些服务器流量异常、负载过大,甚至是大流量的恶意攻击访问等,进行并发数[...]