[WordPress] 外掛分享: WP-Force Images Download

WordPress 外掛 WP-Force Images Download 的封面圖片。

前言介紹

  • 這款 WordPress 外掛「WP-Force Images Download」是 2014-10-20 上架。
  • 目前有 90 個安裝啟用數。
  • 上一次更新是 2025-10-25,距離現在已有 124 天。
  • 外掛最低要求 WordPress 3.0 以上版本才可以安裝。
  • 有 8 人給過評分。
  • 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。

外掛協作開發者

nazakatali32 |

外掛標籤

force images download | featured imgae download | generate download button | pictures download button | templatetag force download |

內容簡介

這是一個簡單的外掛,允許您強制下載圖像或圖片,例如 jpeg、png 等等。
此外掛非常適合想要下載文章附件或特色圖片的人。只需在 single.php 中放置範本標籤,此外掛就會自動為每篇文章產生下載連結。

注意:文章必須具有特色圖片,因為此外掛會為每篇文章的特色圖片產生下載鏈接,如果文章沒有特色圖片,下載按鈕將不會顯示。
使用短代碼,您可以為每個按鈕設置“自定義圖像鏈結”。您可以在單個頁面/文章上使用多個短代碼。

新增功能

現在可以在短代碼中添加自定義 CSS 類。例如

[wpfid class="myclass"]
此類可用於為每個按鈕提供自定義外觀。進入 設置 >> Wp-Force Images Download 頁面,在此添加您的 CSS 代碼並保存設置。

在使用模板標籤下載圖像文件時更改文件名
現在您可以在使用模板標籤下載圖像文件時更改文件名。
請注意,模板標籤有三個參數:

第一個參數用於更改下載按鈕上顯示的文本。默認為 Download
第二個參數用於更改顏色方案
第三個參數用於更改下載時圖像的名稱。
如何使用:請參閱以下示例
例子:
<?php wp_fid("Some Text","green","NEW FILE NANME");?>
<?php wp_fid("Some Text","green",get_the_title());?>
<?php wp_fid("Some Text","green",current_time('timestamp'));?>
<?php wp_fid("Some Text","green",get_the_title().current_time('timestamp'));?>

需要任何幫助?發布您的問題

現在您可以在下載時重新命名圖像。有兩種方法可以重新命名。

1. 使用短代碼

[wpfid new_name="new-name-of-file"]
您也可以像這樣使用變量

[wpfid new_name="%post_id%"]
[wpfid new_name="%filename%_%rand%"],等等。

注意:

您只需指定名稱即可,不需要文件擴展名。

有任何問題?讓我知道__在支持頁面上發布您的問題。

2. 批量重命名圖像

前往 設置 >> Wp-Force Images Download 頁面,設置所需的圖像重命名組合,例如 %filename%-%rand%

默認值:none
注意:這些變量將被替換為相應的值。您可以使用任何組合,例如 %site_name%_%filename%-%post_id%。
此選項不會重命名原始文件。如果您為單個圖像設置了短代碼中的新名稱,則優先使用短代碼中的名稱。
%site_name%:替換為網站標題。轉到 設置 >> 一般 >> [網站標題],以更改此值。
%post_title%:替換為當前文章標題
%timestamp%:以 Unix 時間戳格式替換為當前時間
%post_id%:替換為當前文章 id
%rand%:在 0 到 100000 之間替換為 5 位隨機數字,例如 82469
%md5%:替換為原始文件名的 md5 哈希值
%filename%:替換為原始文件名

原文外掛簡介

This is a simple plugin that allows you to force the download of images or pictures such as jpeg, png, etc.
This plugin is very useful to those who want to download post attachments or featured images. Just put the template tag in single.php and this plugin automatically generates the download link for every post.
Note: The post must have a featured image because this plugin generates a download link of the attached featured image of every post, if the post(s) have not featured image the download button would not appear.
By using shortcode you can set your “custom image link” for each button. You can use multiple shorcodes on single page/post.
NEW FEATURES ADDED

Now custom CSS class can be added in shortcode for each button. Example

[wpfid class="myclass"]
This class can be used to give customized look for each button. To add your custom CSS code
Goto settings >> Wp-Force Images Download page and add your CSS code here and save settings.

Renaming Image file on download when using template tag
Now you can rename iamge file when it is downloaded using template tag.
Note there are three parameters for template tag

First one to change TEXT that would appear on download button. By Default its Download
Second parameter to change color scheme
Third parameter is to change name of image on download.
How to use it: See example below
Example(s):



Need Any Help? Post your Question
Now you can rename images when downloaded.There two ways to rename.
1. Using Shortcode

[wpfid new_name="new-name-of-file"]
You can use variables also like this

[wpfid new_name="%post_id%"]
[wpfid new_name="%filename%_%rand%"] , etc.

Note :
You have to specify name only without file extension.

Have Any Question? Let me know__post your question on support page.

2. Bulk Rename Images
Goto settings >> Wp-Force Images Download page and set your desired combination to rename images. e.g. %filename%-%rand%

Default value:none
Note: These variables will be replaced with their corresponding values.You can use any combination.e.g. %site_name%_%filename%-%post_id%.
This option will not rename original files. If you set new name in shortcode for individual images, the name in shortcode will be preferred.
%site_name%: Replaced with the site title. Goto Settings >> General >> [Site Title] to change this value.
%post_title%: Replaced with the current post title
%timestamp%: Replaced with the current time in unix timestamp format
%post_id%: Replaced with the current post id
%rand%: Replaced with the 5-digit random number between 0 to 100000 e.g. 82469
%md5%: Replaced with the md5 hash of orginal filename
%filename%: Replaced with the orginal filename

Now you can set your own custom download link in shortcode.
e.g.
[wpfid link=”http://link-to/your/image.jpg”]
HOW TO USE THIS PLUGIN:

This plugin can be used in two ways:

by using template tag
by using shortcode

1). By Using Template Tag
You have to put the template tag in your single.php file of your theme, where you want to appear the download button.
There are three ways to use template tag

This is simple form with default settings.
This will allow you to set custom text to appear on download button. Default is Download
This will allow you to set custom text along with custom color (e.g. pink,green,yellow,purple,#ffcc66,#cccccc,#f80, rgb(255,56,35) etc). Default color is grey
This will allow you to set custom text,custom color, new name of image when downloaded.

More Examples:




Second function allows you to set custom text for download button.e.g.

The default title text is Download and default color is grey.

Note:If Featured Image is not set for post the download button would not appear on page.

2). By Using Shortcode
You have to put shortcode in the post content or page, while writing post.
There are five ways to use SHORTCODE.

[wpfid] This is simple form with default settings.
[wpfid title="some text"] This will allow you to set custom text to appear on download button. Default is “Download”
[wpfid title="some text" color="green"] This will allow you to set custom text along with custom color. Default color is “grey”
[wpfid title="some text" color="green" link="http://link-to/your/image.jpg"] This will allow you to set custom text, custom color and custom download link.
By Default download button will download Featured image of the Post or Page where you have added shortcode , if you have set featured image.
[wpfid title="some text" color="green" link="http://link-to/your/image.jpg" class="my_custom_class"] This will allow you to set custom text, custom color, custom download link and custom CSS class.
This class can be used to give customized look for each button. To add your custom CSS code
Goto settings >> Wp-Force Images Download page and add your custom CSS code here and save settings.

各版本下載點

  • 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
  • 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「WP-Force Images Download」來進行安裝。

(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。


1.2 | 1.3 | 1.4 | 1.5 | 1.6 | 1.7 | 1.0.0 | 1.1.0 | 1.1.1 | 1.2.1 | 1.3.1 |

延伸相關外掛(你可能也想知道)

暫無相關外掛推薦。

文章
Filter
Apply Filters
Mastodon