龙风

Results 124 comments of 龙风

多文件上传控制并发 ```js // 文件数组 const files = [file1, file2, file3, ...]; // 并发上传的最大数量 const maxUploads = 3; // 上传文件的方法 async function uploadFile(file) { // 上传文件的代码 } // 使用Promise.all()方法上传文件 async function...

如果a标签打开一个链接打开预览的话,可以按以下解释处理 前端 -----> 图片url + '?response-content-disposition=attachment ' 即可 **response-content-disposition=attachment 解释** response-content-disposition=attachment 是一个 HTTP 响应头字段,用于指示将响应的内容视为附件并将其下载到用户的计算机上,而不是在浏览器中直接显示。 当服务器向客户端发送文件时,可以通过设置 response-content-disposition=attachment 头来指示浏览器将文件下载到用户的计算机上。这通常用于传输二进制文件,如图像、音频、视频、文档等。 例如,当您在网站上点击“下载”按钮时,服务器会通过设置 response-content-disposition=attachment 头将文件下载到您的计算机上,而不是在浏览器中直接打开或显示文件。这可以确保文件的完整性和安全性,并方便用户保存和管理文件。

张鑫旭博客链接: - [WAI-ARIA无障碍网页应用属性完全展示](https://www.zhangxinxu.com/wordpress/2012/03/wai-aria-%e6%97%a0%e9%9a%9c%e7%a2%8d%e9%98%85%e8%af%bb/)

对于progressbar 动态朗读,参考文章 This HTML5 progress bar has been implemented with aria-live="polite" as the only ARIA in use. The separate announcements by screen readers for the progress bar and textual updates...

规范查询 [无障碍网页标准规范](https://www.cnblogs.com/xuegu/p/6431333.html)

另外的一个分享,如何在h 函数上使用自定义指令 ```vue import { defineComponent, h, withDirectives } from 'vue'; import { Button } from 'tdesign-vue-next'; import { upgrade } from '../directives/upgrade'; export default defineComponent({ name: 'PrivilegeBtn', setup(props, {...

SQL注入防范 举例中: mysql中的一些介绍 [文档不错, 值得一看](https://github.com/mysqljs/mysql) ```js var userId = 'some user provided value'; var sql = 'SELECT * FROM users WHERE id = ' + connection.escape(userId); connection.query(sql, function (error, results,...

https://stackoverflow.com/questions/17846529/could-not-open-a-connection-to-your-authentication-agent

安装 git ```bash yum install git ``` 安装node ```bash yum install nodejs ```

安装nvm [可参考该文章](https://developer.aliyun.com/article/972965) ```bash wget https://github.com/nvm-sh/nvm/archive/refs/tags/v0.39.1.tar.gz ``` ```bash tar -zcvf 压缩文件名.tar.gz -C /home # -C 解压到指定目录 ``` 编辑bashrc 文件 ```bash vim ~/.bashrc ``` ```bash export NVM_DIR="/home/nvm-0.39.1" [ -s "$NVM_DIR/nvm.sh" ] &&...