location /chat { proxy_set_header Connection ""; proxy_http_version 1.1; chunked_transfer_encoding off; proxy_buffering off; proxy_cache off; proxy_read_timeout 1h; proxy_pass http://xxx.xx/path/to/sse; }
function copy(message) { // 创建输入框元素 let oInput = document.createElement("input"); // 将想要复制的值 oInput.value = message; // 页面底部追加输入框 document.body.appendChild(oInput); // 选中输入框 oInput.select(); // 执行浏览器复制命令 document.execCommand("Copy"); alert("已复制"); }使用原生命令Copy实现参考:vue实现复制功能
chrome://net-internals/#hsts地址栏中输入 chrome://net-internals/#hsts在 Delete domain security policies 中输入项目的域名,并 Delete 删除可以在 Query domain 测试是否删除成功来源:如何禁止chrome浏览器http自动转成https
location ~* \.(eot|otf|ttf|woff|woff2)$ { add_header Access-Control-Allow-Origin *; expires max; }
由于项目需要,有些内容固定了。 function sharePNG($id, $avatarPath = '', $name = '', $desc = '') { if(substr($avatarPath,0,2) == '//'){ $avatarPath = (\request()->protocol() == 'HTTP/1.1'?'http':'https').":$avatarPath"; } $len = mb_strlen($name); if($len > 11){ $name = mb_substr($name,0,11).'...'; } $path = public_path("/static")
风里来
最后,我终于解放了我自己……