
內容簡介
這個外掛可以幫助您為您的網站添加上傳文件的功能,透過簡單的短代碼或自定義功能,設置最大上傳大小、允許的文件擴展名等等。
完全使用 AJAX,在一個優雅的方式下處理上傳,您只需要將短代碼添加到您的內容中,或在您的代碼中調用插件的自定義函數就可以了。
您可以在前端使用 [ajax-file-upload /*設置作為屬性*/] 短代碼來顯示快速媒體上傳按鈕,或在您的 PHP 模板中使用 do_shortcode('[ajax-file-upload ..]'),或使用內置函數 ajax_file_upload( $args ),當您在函數參數中設置設置為陣列時(對於混淆的情況,它們的作用就像短代碼屬性)。
一些功能:
上傳任何類型的媒體,只要您的設置允許,就容易方便
設置文件擴展名以限制上傳自定義擴展名的文件,例如圖像(jpg,png,gif,bmp..)
設置最大上傳大小,當用戶嘗試上傳較大的文件時,他們將收到一個通知(您完全可以自定義)
自定義權限上傳,您可以選擇允許某些用戶角色、僅限於已登錄的用戶或所有人上傳!
完全可擴展,並創建定制的 JavaScript 事件,您可以將其鉤住以獲取上傳數據設置、響應、文件和更多信息(請查看文檔)
您可以隨時在短代碼之間切換設置,您並不需要使用相同的設置,但是當短代碼設置為空或未設置唯一標識符屬性時,這種情況下,將使用默認設置(您可以在管理員中更改)。
此外,還支持子主題。您可以將整個插件文件夾複製到子主題中,然後修改 JavaScript、CSS 甚至短代碼模板和其他文件。基本上任何文件,除了主加載器文件。
這是一個完全免費和開源的插件。您可以對其進行貢獻,fork 它在 Github 上,將其包含在您的項目中等等,隨時都可以自由地這樣做。根據 GNU GPL 授權,就像主要的 WordPress 插件和 WordPress 本身。
如果您喜歡它,請在 WordPress 上給我們留下有用的評論,將其分享到社交媒體上並為 Github 存儲庫加星。提前感謝您!
有關更多有用的文檔,可以在 Github 上找到 https://github.com/elhardoum/AJAX-File-Upload,您可以隨時通過此聯繫表格聯繫我:http://samelh.com/contact/
外掛標籤
開發者團隊
原文外掛簡介
This plugin will help you add file upload feature to your site, set maximum upload size, allowed file extensions, and much more through a simple shortcode or a custom function.
Totally AJAX, your uploads will be processed faster and an elegant way. All you need to do is to add the shortcode to your content, or call the plugin’s custom function whithin your code and that’s it.
You can either use [ajax-file-upload /*settings as attributes*/] shortcode to display the quick media upload buttons in the front-end, or use do_shortcode('[ajax-file-upload ..]') in your PHP templates, or the built-in function ajax_file_upload( $args ) for which you should set the settings as an array in the 1 function parameter (those act like shortcode attributes, in case of confusion).
Some featues:
Upload any type of media as long as your settings allow, nice and easy
Set file extensions to let limit the uploads to only custom extensions, like for instance images (jpg,png,gif,bmp..)
Set maximum upload size and when a user tries to upload a larger file, they will get a notice (which you can totally customize)
Custom permission to upload, you can choose to allow uploads to certain user role, or logged-in users only, or everyone!
Fully extensible, and creates custom JavaScript events which you can hook into to get the upload data settings, response, file, and much more (view docs)
You can always switch between settings from a shortcode to another, you are not obliged to use the same settings, but when a shortcode’s settings are empty or the unique identifier attribute is not set then in this case, the default settings (you can change them in the admin) will be used.
Also, supports child theme. You can copy the entire plugin folder to your child theme and there modify the JavaScript, CSS, and even the shortcode template and other files. Basically any file except the main loader file.
This is totally free and open source plugin. You can contribute to it, fork it on Github, include it in your project and much more and always feel free to do so. Licensed under GNU GPL, just like major WordPress plugins and WordPress itself.
If you liked it, please leave us a useful review here on WordPress, share around the social media and star the Github repository. Thank you in advance!
More useful documentation can be found on Github https://github.com/elhardoum/AJAX-File-Upload and you can contact me anytime from this contact form: http://samelh.com/contact/
