Сб 1 Гру, 2007
Description:
Post Attached Image plugin adds a image thumbnail suggested by user to any post in list and a large image on the single page. It is usefull to create a products catalog for example.
Instalation:
- Upload the file post-attached-image.php to the /wp-content/plugins/ directory
- Activate the plugin through the ‘Plugins’ menu in WordPress
- Configure the plugin in the ‘P-Image’ menu located under the WordPress ‘Options’ menu
It’s needed to edit a little file /wp-admin/edit-form-advanced.php at line 12
_<form_
must be
_<form enctype=”multipart/form-data”_
Without this string file will not be uploaded.

Usage:
Use file input field under the post visual editor to upload image
Download
Popularity: 13% [?]

Leonaut.com says:
Post Attached Image…
Post Attached Image plugin adds a image thumbnail suggested by user to any post in list and a large image on the single page. It is usefull to create a products catalog for example….
Joshua A.C. Newman says:
I get an error when I try to alter (or even save) the settings:
Cannot load poster-thumbs.php.
Unfortunately, I haven’t even determined if this plugin does what I’m after: I’m trying to get icons in the pages list in the sidebar, and this maybe does it on the category page?
Maybe you can help me out.
Thanks!
-Joshua
Poster says:
I’ve uploaded a new version of file.
It is needed to make some changes in file /wp-admin/edit-form-advanced.php at line 12
_<form_
must be
_<form enctype=”multipart/form-data”_
Mazen says:
Hey Mate,
Thank you for this plugin, It is really great.
I have istalled it on my fiance blog: http://www.watchorskip.com and it is working beautifully.
Just a couple of suggestions for your next realese:
1. Add the alt and title tags to the code so that the pages with the images validate. Specifically line 433.
2. Add post Image layout controls to the admin page, I had to do them manually by editing the plugin file
Currently you can only control thumbnail layout.
I have edited the mentioned line so I get the image floating with text wrapped around it, rather than having it seperate from the text, I added horizontal and vertical spacing, and the alt and title tags, my final line is like this:
_$content = ”.$content;_
Check it out on the site it is looking great.
Thanks again.
Cheers.
Mazen says:
The comment is stripping of the code
Give me your email address and I will send you the code.
Cheers.
Crni says:
I don’t see in a edit-for-advanced.php place when I need to do changes.
I see all, and bar for uploading image but it doesn’t work.
Crni says:
Ok I fixed it.
But here is what I want: to place a picture like the left aligment on the main page.
Like it is in this blog which is in comments.
Can you tell me how to make this plugin to work just like that.
You can delete previous comment.
Mazen says:
crni, I have not developed the plugin, the author should respond, however I can help you. I bled my eyes to make it work the way you see it.
Email me through the contact form on my blog and I will tell you how.
http://www.mazenville.com/contact
Sorry but I do not want to publicize my email address.
Cheers.
Poster says:
It seems I found the decision to set enctype for the form using javascript.
Poster says:
I’ve already updated this plugin (added alts and titles to images and javascript to set encoding type)
Joerg says:
Today, 1.1.2008, all the images of the year 2007 are not displayed as Thumb and not in the post. What is wrong?
Mazen says:
Hey Joerg,
That is true, happened to me too.
Apparently the plugin creates a folder "Uploads" in your wp-content folder, which is divided into subfolders by Year and Month.
Hence, all the photos you add today, will be in "01" folder under "2008" folder under "uploads" in your wp-content.
Everything you have will be there now in "2007" folder, so you have not lost your photos or automatically generated thumbs. I am not sure if recopying all these under "2008" solved the problem, what I did is that I downloaded the 2007 folder and reassigned all the photos from it to the posts again. I dont have a lot that is why (around 18 posts).
Hope this helps, waiting for Poster’s (the author) reply.
Cheers.
Joerg says:
@Mazen: Recopying the "month" folder in the year 2008 doesn’t work.
Mazen says:
Then my friend…I am afraid you will have to walk my walk:
Reassign all images to them posts again…
Joerg says:
@Mazen: I found the problem, but I’m not able to solve it:
It’s a problem, when you use the year and month option for your upload (Options/Misc).
The plugin use the actually folder, that means today the "2008/12" folder. When you manually make a reassign now for older posts, the plugin use the "2008/12" folder and the next month they will disappear again.
A solution is to not use the option for years and month folder. But I don’t like that solution and I’m to bad in coding to solve the problem. I hope of a better solution for this creat plugin.
Mazen says:
@ Joeg: Nice catch man.
Poster…please help
Cheers.
adi says:
how can make it work with TDO mini Form Plugin, need help here ..
Poster says:
Today you will get a new update. I think the problem is in $uploads = wp_upload_dir()
but why does it mistakes…
Poster says:
So update is ready. Plugin at the moment easily gets right uploads dir
Joerg says:
Thank you Poster for the update and the great idea for this plugin. I love it.
Robert Kroone says:
I am trying you plugin. I like it, but i would like to get more control over the layout. For example; I would have the text around/at the right or the left of the category thumb.
Can you help me out on how to do this?
Thx.
Mazen says:
Hey Poster,
Thanks for the update man.
Do I need to reinstall the whole plugin or only modification for a single line of code?
Please let me know.
Cheers.
Poster says:
to Robert Kroone
Try to edit the template by adding styles (float: left or float: right) or add the table as template
to Mazen
You don’t need to reinstal the plugin. It doesn’t uses any DB
Yappy says:
hi!
I’ve tried the plugin and it’s great.
But my question is how do i move the thumbnail to the ‘recent post’, instead of the post itself?
Yappy says:
i’m trying to move the thumbnail to appear under the ‘recent post’ column, not in the post itself
Poster says:
Can you show an example?
This plugin works when the_content() in template is called, and in that place
Poster says:
I’ve updated plugin. Now it is posible to upload more than one image
Giovanna Papetti says:
Sorry, it’s possible view the thumb outside the loop? into a sidebar example? sorry for my bad english, i’m italian…
Poster says:
I’ll add support for sidebar soon
dan says:
hi poster, thanks for the great plugin. How can I remove an uploaded image from the post? Is there any "remove" option?
adi says:
why all pic from my blog not showing??
chris says:
Bullshit plugin no remove, wtf?
Anne says:
Hi! This plugin is just what I need. But I can´t make it work..
I can upload pictures but the thumbnail is not shown
line 12 in my "edit-form-advanced.php" look like this:
What can be wrong?
yest says:
hello
im looking for this wiget a while
this is line 12 in the file, what i have to write:
thank u
Ruben says:
Hi, great plugin but for some reason on some of my post excerpts it adds a second thumbnail (with the same link and code). The second thumbnail gets added below the excerpt and is an exact copy of the first one. I have no idea why it does this, and it’s not on every post. Does this mean anything to you? Where could the problem be?
yest says:
can u write please how the code should be … all the code… thank u
yest says:
can someone help me please
this is what written in line 12:
__
what will be the new line????
Poster says:
I’v added images “before and after” to the post.
Try to enable JavaScript before editing files, or add your site to trusted – it must work without editing.
yest says:
thank u very much
yest says:
i did it all and still i cant see the upload bottom…whats wrong?
Brams says:
Hi poster. Great plugin.
However it only works on my single post page, but not with the excerpts in my category page and index page. (the thumb doesn’t exist when I look at the source code on these pages)
The thumbnails are properly generated and stored in my uploads folder.
What code should I add to have them show up, and in what page?
Thank you for the help.
Poster says:
Brams, what template are you using?
Wazi says:
So, perhaps I’ve done something wrong, but when trying out this plugin, I get the following error:
Fatal error: Call to undefined function imagecreatefromjpeg() in /Library/WebServer/Documents/blog/wp-content/plugins/post-attached-image.php on line 419
any advice?
Wazi says:
Follow up – my fatal error was, I believe, caused by my webserver set up not allowing pretty permalinks. that’s been resolved, but now I have a different problem – the picture does not upload.
Is there supposed to be an "upload" button? or does it just upload when the post is saved or published?
If it just uploads when you save, or publish, the post, I’m getting nothing, and I’ve edited line 12 of the file mentioned. Still nothing.
Advice?
Poster says:
You don’t have GD library (for editing images) installed. Write a letter to your hosting support
yest says:
can u make it sutibele for wordpress 2.5???
hip hop news says:
Exactly what I was looking for, finally! Thank you.
Jevgenij says:
PHP Warning: Variable passed to each() is not an array or object in \wp-content\plugins\post-attached-image\post-attached-image.php on line 76
reset() [function.reset]: Passed variable is not an array or object in \wp-content\plugins\post-attached-image\post-attached-image.php on line 73
Jevgenij says:
Wordpress 2.5.1: Images don’t uploded, and some php errors from log file
PHP Warning: Variable passed to each() is not an array or object in \wp-content\plugins\post-attached-image\post-attached-image.php on line 76
reset() [function.reset]: Passed variable is not an array or object in \wp-content\plugins\post-attached-image\post-attached-image.php on line 73
Jevgenij says:
Sorry for dublicated post
Jevgenij says:
в 2.5 вордпрессе не работает.
Альф says:
ага в 2.5 не хочет работать =(
Sergey says:
Может кто нибудь доработать плагин, так чтобы он вместо одной миниатюры добавлял 3.
icq: 525495
оплата WMZ и т.п.
Michael says:
I’ve added the enctype="multipart/form-data" snippet to form tag, but I’m still not seeing an upload button when I go to write a post.
Paul says:
I’ve added the enctype="multipart/form-data" snippet to form tag.
PHP Warning: Variable passed to each() is not an array or object in \wp-content\plugins\post-attached-image\post-attached-image.php on line 76
reset() [function.reset]: Passed variable is not an array or object in \wp-content\plugins\post-attached-image\post-attached-image.php on line 73
Richard says:
Thanks this is exactly what i was looking for
frank says:
entered the (enctype="multipart/form-data") code also and still unable to upload images. Any hints?
SebyRollins says:
Merci pour ce bon, simple et util plugin
Thank’s for this simple and pratical plugin
Mazen says:
Hello Guys,
Please make sure you are downloading and installing the latest plugin v1.1 the version before that does not work with latest WP release.
Plugin Author,
Thanks for the plugin updates. I can see you have taken all the suggestions as and applied them to the latest version so thanks for that.
There is one bug in the plugin. Now since you can upload up to 5 files at once, the exported image names are in this format:
Image: postid_#pos.jpg
Thumbnail: thumb_postid_#pos.jpg
Where "#" for both is the number of image between 1 and 5 in order of upload.
It is working fine for single post images, but thumbnails are not displaying anymore in listing page (category). I kept trying to figure out why especially that I saw the script is working fine and generating the post thumb, then eventually it ocurred to me that the problem is with the filename.
When I edited the thumbnail filename and removed the "#" bringing it back to old filename format, the thumbnails displayed again in listing pages.
This applied to newly uploaded images, not the old ones. The code is taking care of the old ones.
Please help with a fix with either:
1. Generating thumbnail names without #
2. Updating the code to read thumbnails with the name including #
Cheers buddy.
Outsource Web Design says:
Thanks for the plug-in first of all.
Am new to your plug-in.
Using it in http://www.buyastro.com/category/homas
Both in categories page, as well as full post page, the text starts very immediate after the image. Tried in the post start and it didn’t helped me. Can you please write some tips on how do i get the content displayed after a line from the image?
Thanks once again for the plug-in.
Carlos says:
hey,
i’m using it but the upload doesn’t work.
there is no file in my directory for upload.
i can’t find a solution.
and other thing: instead of a diferent upload, i think it’s a good idea to retain some reference from the post upload. i imagine that would be commom to use a image from a post as the thumbail (rezised, course).
thanks
newuser says:
Hi Poster,
I changed the form in Wordpress MU, on line 48, but the word "multipart" does show as black color as in your demonstration, it is red color, but the word /form-data is black color. Can you comment on this? I have added that line but it still doesn’t allow me to upload. Thank you for your help.
Poster says:
I’m sorry. But this plugin was not tested under WordPress MU, and I think it will not work at the time
newuser says:
I tried with WP 2.7, and the edit-form-advanced.php doesn’t look like what you have said. how I do fix this problem? there is button to browse the picture and it was added, and can be deleted but no floating window to edit the picture and the picture is not showing. please help. thank you.
Ben Klinger says:
is there a way to show the excerpt in the category view?
thank for the great plugin.
ир says:
until the upload in wp 2.7 is not functioning, upload the file manually (to the correct directory), making sure you follow the naming settings (prefix + postid + suffix), just to be able to use this nice plugin.
andrew says:
Hello There,
Just installed v1.1 in WP 2.7 – and do not see any fields where a user can upload an image. Also, my edit-form-advanced.php file looks much different than your example, so I could not edit line 12 as suggested.
Thus far, I have installed, and looked at the options page – but the options page looks like it is just to change the layout of the images. Is there anything that I need to do, to allow this plugin to work?
Thanks in advance,
andrew
http://www.throwingthisaway.com
presto says:
Hi nice plugin, but how can i delete the attached image, how can i view it in edit post page.
May be this is useful?
presto says:
Hi i suggest you to update your plugin. For some reason we may need to call the attached img without the_excerpt.
So you can add to your plugin this code.
function post_attached_img() {
global $id;
global $post;
$file = $id . get_option(’pthumb_sufix’) . ‘.jpg’;
$uploads = poster_upload_dir($post->post_modified);
if (file_exists($uploads['path'].’/’.get_option(’pthumb_prefix’).$file)) {
echo ‘‘;
}
}
And the template tag is:
php post_attached_img(); ? >
Everibody can add in functions.php to use it.
Rick says:
I was wondering if there’s an updated version of this plugin on the way? Has anyone tweaked it to work to their liking?
Lastly, why don’t my post images appear in RSS feeds? Is there a way to fix that?
最好的WordPress日志编辑、显示相关插件推荐 - 电脑阁·PCrooms 小杰的互联网世界 says:
[...] 而在单页则会显示大图. 比较适合用来创建产品目录的一个Wordpress插件. 插件主页 Advanced Excerpt Wordpress高级摘要插件. [...]
60余款Wordpress日志插件/文章编辑插件 | LoveTree says:
[...] Post Attached Image Post Attached Image这个插件可以让用户为每篇文章添加缩略图, 而在单页则会显示大图. 比较适合用来创建产品目录的一个Wordpress插件. 插件主页 [...]
那些网事 says:
[...] Post Attached Image这个插件可以让用户为每篇文章添加缩略图, 而在单页则会显示大图. 比较适合用来创建产品目录的一个Wordpress插件. 插件主页 [...]
Wordpress缩略图插件 | 帕兰映像 says:
[...] Post Attached Image [...]
60+Wordpress日志插件/文章插件 | 帕兰映像 says:
[...] Post Attached Image Post Attached Image这个插件可以让用户为每篇文章添加缩略图, 而在单页则会显示大图. 比较适合用来创建产品目录的一个Wordpress插件. 插件主页 [...]
wordpress做电子商务或产品展示网站必不可少的插件 | 来补脑---你的个人技术指导!每天都新鲜 says:
[...] Post Attached Image [...]
Chantal says:
Hi…
Love the plugin… Is there anyway that if you click on the image in the simgle post, that it goes to the full huge image? Ie in http://theantoerien.co.za/thean/?p=30, I would like the viewer to click on the image and it open in ina new page with a larger image? Thank you
Regards
tester says:
in the 2.8.4 version just make the change in the same file on the line: 563.
It`s working well
50款超级强大的Wordpress日志插件/文章插件 « 赢在博客 says:
[...] Post Attached Image Post Attached Image这个插件可以让用户为每篇文章添加缩略图, 而在单页则会显示大图. 比较适合用来创建产品目录的一个Wordpress插件. 插件主页 [...]