iDeasilo

Tam-attachment

I’m busy now. Current version of tam-attachment does not work on WordPress 2.1, but I don’t have time to fix it until March. We’re sorry for the inconvenience.

現行バージョンの tam-attachment は WordPress 2.1 上で機能しません。すぐに直したいのですがしばらく多忙のため3月以降になるまで対応できません。不都合をおわびします。

» 日本語

Summary

Tam-attachment is a WordPress plugin which adds some powerful functionality to native file attachments mechanism. This plugin allows you to edit file title and description at any time, not only at file uploading time. And also it offers a couple of useful features like …

The plugin has own good-looking edit panels similar to the familiar Post and Page edit panels. You can edit slags, order, discussion settings, password, parent post and custom fields on it.


Usage

You can upload files via either native inline uploader or new [Manage] » [Attachment] panel. In the panel if you have orphaned files or files without attachment in your upload directory, they will be shown and suggest creating attachment for them. [After attachment feature]

Then you can select an attachment in Attachment Management pane and edit your attachment in new [Write] » [Write Attachment] panel. In the panel, you can upload extra thumbnail image from Files sidebar. [Original thumbnail feature]

And you can put tags from Tags bar. [Tagging feature]

Template functions

There are some template functions you can use in template PHP:

Here is an example. Getting attachments with tag ‘photo2005’ and display the title, icon image which limited by the size 128×128, content and link to the attachment.

<?php
$attachments = $tam_attachment->get_attachments('photo2005');
if ($attachments) {
  foreach ($attachments as $attachment) {
    $attachment = $tam_attachment->get_attachment($attachment);
    echo '<a href="' . $attachment['attachment_link'] . '">';
    echo $attachment['post_title'];
    echo $tam_attachment->get_icon($attachment['ID'], array(128, 128));
    echo $attachment['post_content'];
    echo '</a>';
  }
}
?>

Download and Installation

You can download the plugin’s zip file here. After you download the zip, you’ll need to unzip it to your <WP_INSTALL>/wp-content/plugins/ directory. Then log into WordPress and activate the plugin from within your plugins panel.

Changelog

Version Date Description
0.1 2006/06/18 Initial release
0.1.1 2006/06/18 Bug fix
0.1.3 2006/07/26 Bug fix

このプラグインは何か?

Tam-attachment プラグインは WordPress のアップロードファイル管理の仕組みにいくつかの強力な機能を追加します。これを使えばファイルのタイトルや説明をいつでも好きなときに編集できるようになります。さらに tam-attachment は次の便利な機能を提供します。

Tam-attachment には扱いなれたポストやページのインタフェイスと同様の格好良いエディット・パネルが備えられており、スラッグや順序、ディスカッション設定、パスワード保護、親ポスト、さらにカスタム・フィールドの編集をそこで行なうことができます。

使い方

まずファイルをアップロードして下さい。アップロードするには標準のインライン・アップローダを使っても構いませんし、新しい [Manage] » [Attachment] パネルから行なうこともできます。[Manage] » [Attachment] パネルでは、もしアップロード・ディレクトリの中にアタッチメント化されていないファイルが見つかれば、これをお知らせして後付けアタッチメントを促します。

その後は表示されるアタッチメント一覧から選択して、[Write] » [Write Attachment] パネルから編集が可能になります。このパネルのサイドバーからオリジナル・サムネイルのアップロードが可能です。また、タグの入力も下部のバーから行なうことができます。

テンプレート関数

テンプレートの中で使える関数がいくつか用意されています。

ダウンロードとインストール

ここから zip ファイルをダウンロードして、<WP_INSTALL>/wp-content/plugins/ ディレクトリに展開、あとは WordPress にログインして plugins パネルで有効化して下さい。

日本語翻訳パッケージはここからダウンロードして下さい。展開すると tam-attachment-ja.mo と tam-attachment-ja.po の2つのファイルが入っているので、tam-attachment-ja.mo を <WP_INSTALL>/wp-content/plugins/ 直下に置き、手順に従い WPLANG を ja に指定して下さい。WPLANG の指定を変更できない場合は tam-attachment-ja.mo の方の名前を既定の WPLANG に合わせて(例えば tam-attachment-ja_UTF.mo などに)変更しても構いません。