摘要: 在 PHP 中使用 cURL 上传文件至接口,你可以通过 `CURLOPT_POSTFIELDS` 选项来设置文件的内容。以下是一个示例: ```php function uploadFile(url,filePath, $fieldName) { ch=curlinit(url); 阅读全文
posted @ 2023-06-29 08:57 xingduo 阅读(1682) 评论(0) 推荐(0) 编辑
摘要: ```php class FileUploader { private targetDirectory;privateallowedExtensions; private maxFileSize; public function __construct(targetDirectory, 阅读全文
posted @ 2023-06-29 08:53 xingduo 阅读(25) 评论(0) 推荐(0) 编辑
摘要: 1. 使用 `Object.keys()` 方法检查对象的键值对数量: ```javascript function isObjectEmpty(obj) { return Object.keys(obj).length 0; } // 示例用法 const obj1 = {}; console.l 阅读全文
posted @ 2023-06-19 13:49 xingduo 阅读(84) 评论(0) 推荐(0) 编辑
摘要: 要设置Git忽略文件,你可以使用一个名为.gitignore的特殊文件。在这个文件中,你可以列出需要Git忽略的文件、文件夹、或者匹配模式。当Git执行操作时,它会自动忽略这些被列出的文件。 1. 在你的项目根目录下创建一个名为.gitignore的文件。 2. 打开.gitignore文件,然后逐 阅读全文
posted @ 2023-05-18 14:52 xingduo 阅读(1591) 评论(0) 推荐(0) 编辑
摘要: git全局设置 git config --global user.name "xxxxxx" git config --global user.email "xxxxxx" 创建 git 仓库 mkdir custom cd custom git init touch README.md git a 阅读全文
posted @ 2023-05-18 14:37 xingduo 阅读(15) 评论(0) 推荐(0) 编辑
摘要: {field:'plateNoPicUri', title: '图片' ,width:"10%" ,templet:function(data){ if("" == data.plateNoPicUri || null == data.plateNoPicUri) return ""; var su 阅读全文
posted @ 2023-04-24 17:06 xingduo 阅读(491) 评论(0) 推荐(0) 编辑
摘要: const timestampToTime= (timestamp) => { const date = new Date(timestamp * 1000); const year = date.getFullYear(); const month = (date.getMonth() + 1). 阅读全文
posted @ 2023-04-20 11:56 xingduo 阅读(200) 评论(0) 推荐(0) 编辑
摘要: private function formatISODate($dateTime) { date=date("Ymd",strtotime(dateTime)); time=date("H:i:s.000",strtotime(dateTime)); return $date 阅读全文
posted @ 2023-04-04 10:34 xingduo 阅读(361) 评论(0) 推荐(0) 编辑
摘要: /** * 读取文件 * @param dirname@paramext * @return array */ public static function scan_dir(dirname,ext = "json") { $result = array(); if (is_dir 阅读全文
posted @ 2023-04-04 10:27 xingduo 阅读(16) 评论(0) 推荐(0) 编辑
摘要: import {fileURLToPath, URL} from 'node:url' import {defineConfig, loadEnv} from 'vite' import vue from '@vitejs/plugin-vue' import AutoImport from 'un 阅读全文
posted @ 2023-03-09 17:58 xingduo 阅读(94) 评论(0) 推荐(0) 编辑
点击右上角即可分享
微信分享提示