這個外掛並未在最新的 3 個 WordPress 主要版本上進行測試。開發者可能不再對這個外掛進行維護或提供技術支援,並可能會與更新版本的 WordPress 產生使用上的相容性問題。

Twivatar

外掛說明

Adds twivatar shortcode. When also passed a Twitter handle as the name attribute, the plugin will get the current avatar from Twitter, and store the URL for 24 hours. It then echoes out an image.

Attributes (optional unless marked otherwise):

  • name – Twitter handle. Required.
  • size – One of ‘mini’, ‘normal’ or ‘bigger’ Default is ‘normal’.
  • link – Whether to link the image to the profile page on Twitter. Default is true.
  • linkclass – class attribute value of the link. Default is none.
  • rel – rel attribute value of the link. Default is none.
  • class – class attribute value of the image. Default is none.
  • title – title attribute value of the image. Default is none.

Please report all issue via https://github.com/GaryJones/twivatar/issues.

螢幕擷圖

  • Example of output, as seen at http://bsktweetup.info/

安裝方式

  1. Unzip and upload twivatar folder to the /wp-content/plugins/ directory
  2. Activate the plugin through the ‘Plugins’ menu in WordPress

常見問題集

Where should I report any problems?

Please report all issue via https://github.com/GaryJones/twivatar/issues.

Can I amend how long the image URL is cached for?

Not yet. In a future version of the plugin, you will be able to. Current default is 24 hours.

Can I change the default Twitter image?

Not yet. In a future version of the plugin, you will be able to. Current default is to use an image file called no-twitter-image.png in a folder called images in your active theme.

This image is only used if no image can be determined for the account. Either Twitter is down, or the account doesn’t exist. If the account does exist, but has no image, then the default one that Twitter uses will be stored.

使用者評論

這個外掛目前沒有任何使用者評論。

參與者及開發者

以下人員參與了開源軟體〈Twivatar〉的開發相關工作。

參與者

將〈Twivatar〉外掛本地化為台灣繁體中文版

對開發相關資訊感興趣?

任何人均可瀏覽程式碼、查看 SVN 存放庫,或透過 RSS 訂閱開發記錄

變更記錄

1.0.2

  • Removed array type hint that may not be satisfied in edge cases.
  • Moved main class into its own file.
  • Made the variable that has the instance of the class assigned to it, explicitely global.
  • Added .pot file.

1.0.1

  • Tidy up of old code, including improved i18n support.

1.0.0

  • First public version.