打開config-> database.php
$ database ['localhost'] =''; - >指定您的主機名稱
$ database ['username'] =''; - >數據庫的用戶名
$數據庫['password'] =''; - >數據庫的密碼
$數據庫['database'] =''; - >數據庫名稱
1.從數據庫中選擇數據:selectfromdb($ table_name);
$ table_name-您的數據庫表必須從中獲取數據。
2.從數據庫中選擇單行:selectsinglerecord($ table_name,$ arr);
$ table_name-您的數據庫表必須從中獲取數據。
$ arr:條件中的一系列數據。 $ arr ['id'] = 1;意味著ID = 1
3.從數據庫中選擇行數組:selectsinglerecord($ table_name,$ arr);
$ table_name-您的數據庫表必須從中獲取數據。
$ arr:條件中的一系列數據。 $ arr ['id'] = 1;意味著ID = 1
4.從數據庫自定義查詢的行排列數組:CustomQueryArray($ QUERY);
$查詢 - 從table_name選擇計數(*);
5.從數據庫自定義查詢中選擇單行:CustomQuerySingle($ QUERY);
$查詢 - 從table_name選擇計數(*);
6.update數據:updateData($ table,$ update,$ arr)
$更新 - 要更新的數據數組;
7.刪除數據:deletedata($ table,$ arr)
1.簡單圖像上傳:image_upload($ image_file,$ image_name,$ save_path)
$ image_file =上傳圖像。例如$ _files ['image]。
$ image_name =圖像的名稱(1WAXSC)。不要指定.jpg或.png等。
$ save_path =正確保存圖像的路徑。
2.Base64到映像和上傳:String_image_upload($ image_name,$ image_file,$ save_path,$ width,$ height)。
$ width =保存圖像的寬度。 $高度=要保存的圖像高度。
3.upload映像(圖像壓縮):upload_image_with_compression($ image_name,$ image_file,$ save_path,$ width,$ height)。
4.upload視頻:upload_video($ image_name,$ image_file,$ save_path)。
5.UPLOAD PDF:upload_pdf($ image_name,$ image_file,$ save_path)。
6.upload任何文件:upload_any_file($ image_name,$ image_file,$ save_path)。
1. iMport excel and View in array:read_excel_file($ file);上傳文件。例如$ _files ['文件]
2. excel:convert_excel($ data,$ title,$ filename,$ fontsize);
1. $數據:導出的數據數組。
2. $標題:文件標題。
3. $文件名:保存Excel的文件名。
4. $ fontsize:fontsize。