বৰ্ণনা
WordPress has a wonderful JavaScript/iframe dialog for uploading or choosing images to use
in posts or as featured thumbnails. Repurposing this dialog for other uses is difficult.
Image Upload Helper is a simple library that helps you add an image upload/selection field
anywhere in the WordPress admin, using a single function.
Created by Flightless with significant credit to Modern Tribe
ইনষ্টলেশ্যন
- Upload the plugin to your blog.
- Activate it.
- Nothing happens.
This is a library. It doesn’t actually do anything by itself. To use it in a plugin:
- Include this plugin (in its entirety) in a subdirectory of your plugin. It plays nice with other
plugins; if a site has multiple plugins activated, each with its own copy of Image Upload Helper, only
one will load. require_once( 'image-upload-helper/image-upload-helper.php' );
- Call
image_upload_helper()
wherever you want an upload dialog available.
The image_upload_helper()
function takes an array of arguments to control exactly what the form
looks like.
field_name
– Required. The name of the form field that will be submitted. Defaults to
“image-upload-helper”. Use this to customize the field to fit in with your form. By changing
thefield_name
value, you can callimage_upload_helper()
as often as you like on each page.thumbnail_id
– The attachment ID of the current value of the field.label
– The label to use for the field. Defaults to “thumbnail image”. This will
display as “Set thumbnail image” or “Remove thumbnail image” in the form, or “Use as
thumbnail image” in the iframe dialogsize
– The size of the image you want displayed in the form. Defaults to “post-thumbnail”.
If you want to display a custom size, make sure you register it.
When a form is submitted with an Image Upload Helper field, the field specified by the field_name
argument
will contain the attachment ID of the selected image.
পৰ্য্যালোচনা
এই প্লাগিনৰ বাবে কোনো পৰ্য্যালোচনা নাই।
অৱদানকাৰী আৰু বিকাশকাৰীসকল
“Image Upload Helper” হৈছে মুক্ত উৎসৰ ছফ্টৱেৰ। এইসকল লোকে এই প্লাগিনত অৱদান আগবঢ়াইছে।
অৱদানকাৰীসকলআপোনাৰ ভাষাত “Image Upload Helper” অনুবাদ কৰক।
বিকাশৰ প্ৰতি আগ্ৰহী?
ক’ড ব্ৰাউজ কৰক, SVN ৰিপজিটৰী চাওক নাইবা RSS-দ্বাৰা বিকাশৰ পঞ্জী ছাবস্ক্ৰাইব কৰক।
সলনি-পঞ্জী
1.0
Initial version