[MOD] Image Upload Module (v0.93) -- Please test

Register an Account
Reply
 
Thread Tools Display Modes
  #11 (permalink)  
Old 06-14-2007, 10:41 PM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
Hi adampoots,

What's not working?

Best,
Cent

Quote:
Originally Posted by adampoots View Post
Hmm. i seem to be having a lot of issues getting this one to work. I've even uninstalled pligg and started from scratch following the directions in the readme packed with the 0.93 download.

Could someone perhaps send me the edited, .tpl files?
Reply With Quote
  #12 (permalink)  
Old 06-14-2007, 10:51 PM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
There was mistakenly omitted from the readme...

In your /templates/(your template)/editlink_edit_center.tpl file...

Look for the <form action> line...

Add to it:
enctype="multipart/form-data"

That last part allows for binary files to be attached. That must be added in order to upload photos from the edit entry section.

Best,
Cent
Reply With Quote
  #13 (permalink)  
Old 06-15-2007, 12:36 AM
Casual Pligger
 
Join Date: Jan 2007
Posts: 46
OK, thanks Cent. Now I am able to get some images to upload and display properly, but there seems to be a minimum size limit. So far .jpg files that are about 10kb are not loading properly but those over 100kb work fine.
Reply With Quote
  #14 (permalink)  
Old 06-15-2007, 12:45 AM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
Hi timofsurbia,

Thanks odd. Unless a file is NOT a JPG or over the maxium width/height for displaying on the site, its not even processed by anything and just uploaded, moved (renamed) and stored in the DB.

Can you send me a JPG that is causing the problem (10kb) so I can test on my end? I want to use the same image that you are as opposed to creating one on my end. As there may be certain issues with a particular image that I may not be able to reproduce in the same way.

Thanks

Best,
Cent


Quote:
Originally Posted by timofsuburbia View Post
OK, thanks Cent. Now I am able to get some images to upload and display properly, but there seems to be a minimum size limit. So far .jpg files that are about 10kb are not loading properly but those over 100kb work fine.
Reply With Quote
  #15 (permalink)  
Old 06-15-2007, 12:46 AM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
Hi timorsurbia,

This link http://pandorastations.com/story.php..._Electronica-1 came up as a blank page.

Best,
Cent

Quote:
Originally Posted by timofsuburbia View Post
I think I'm having the "no extension" problem. The image uploads to the image directory, but in the database, there is no .jpg extension, and the image does not appear in the post. The original image uploaded was also .jpg. Images I uploaded using the version .4 did include the .jpg extension and do appear in the post.

http://pandorastations.com/story.php..._Electronica-1

vs.

http://pandorastations.com/story.php..._AMBIENT_RADIO
Reply With Quote
  #16 (permalink)  
Old 06-15-2007, 12:53 AM
Casual Pligger
 
Join Date: Jan 2007
Posts: 46
Sorry about that. I've been fooling a bit with my database trying to solve this.

I am going to try various sizes of this....

http://www.flickr.com/photo_zoom.gne...4708944&size=o

to test my hypothesis that there is some sort of lower limit. I would be happy to be wrong so we'll see.

EDIT: Update, only the largest version of that image seemed to upload properly. 800 x 600.

EDIT2: I seems that I have to drop the maximum height and width down below the size of the images being uploaded for them images to upload properly. For instance if I expect images to be 100 x 100 or higher, then I need to lower those values found in the image_upload_settings.php to under 100 each.

Last edited by timofsuburbia; 06-15-2007 at 01:37 AM. Reason: extra details.
Reply With Quote
  #17 (permalink)  
Old 06-15-2007, 11:35 AM
Constant Pligger
 
Join Date: Oct 2006
Posts: 220
I installed the new version on a 9.5 install of Pligg and I'm still having problems when editing the image as an admin. I can delete an image but can't seem to upload a new one. This is what i get when trying to upload a replacement image in debug mode:

START: image_upload_preview_handler
Story ID = 17
Image Path = test/00photos/img_17
Image Caption = askjdas dkjhasd
Image File = img_17
No image found to display.
END: image_upload_preview_handler



I had the the previous version of image upload on this site and simply uninstalled it and deleted it and then uploaded and installed the new version. I don't know whether there's something i forgot to delete from the old version that could be causing problems ... but the new version seems pretty self contained.

Sorry I can't give an url right now ... it's on a protected dev server.

Last edited by revolver; 06-15-2007 at 12:17 PM.
Reply With Quote
  #18 (permalink)  
Old 06-15-2007, 12:16 PM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
revolver,

If you can upload an image with a new entry, delete a photo when editing but cannot upload a new one, then try:

Open /templates/(your template)/editlink_edit_center.tpl

and look around line 25 for the <form action> line... change it to:
<form action="" method="post" id="thisform" enctype="multipart/form-data">

the enctype addition is necessary for file uploads.

let me know how that works for you.

best,
cent


Quote:
Originally Posted by revolver View Post
I installed the new version on a 9.5 install of Pligg and I'm still having problems when editing the image as an admin. I can delete an image but when i upload a new one it doesn't show up.

I had the the previous version of image upload on this site and simply uninstalled it and deleted it and then uploaded and installed the new version. I don't know whether there's something i forgot to delete from the old version that could be causing problems ... but the new version seems pretty self contained.

Sorry I can't give an url right now ... it's on a protected dev server.
Reply With Quote
  #19 (permalink)  
Old 06-15-2007, 12:38 PM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
Timofsurbia,

I believe I just fixed this problem. The filename wasn't being appended with ".jpg" for images that were smaller (width/height) than the settings and a JPG file. If you can try the attached file... its a direct replacement for the one you have installed and let me know if that works for you.

Best,
Cent


Quote:
Originally Posted by timofsuburbia View Post
Sorry about that. I've been fooling a bit with my database trying to solve this.

I am going to try various sizes of this....

http://www.flickr.com/photo_zoom.gne...4708944&size=o

to test my hypothesis that there is some sort of lower limit. I would be happy to be wrong so we'll see.

EDIT: Update, only the largest version of that image seemed to upload properly. 800 x 600.

EDIT2: I seems that I have to drop the maximum height and width down below the size of the images being uploaded for them images to upload properly. For instance if I expect images to be 100 x 100 or higher, then I need to lower those values found in the image_upload_settings.php to under 100 each.
Attached Files
File Type: zip image_upload_main.zip (4.2 KB, 37 views)
Reply With Quote
  #20 (permalink)  
Old 06-15-2007, 01:03 PM
Constant Pligger
 
Join Date: Oct 2006
Posts: 220
@ cent ... the fix works like a charm.

everything seems to be working fine on my server now.
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Upload Module (File and Image Attachment) Yankidank Free Modules 268 02-03-2012 12:19 PM
[MOD] Image Upload Module (v1.0) -- Now Available cent Questions and Comments 190 01-08-2011 05:12 PM
Simple question: Has anyone got the image upload module to work? Citizenslide Questions and Comments 7 07-30-2009 02:44 AM
Image Upload Module - Really confused thefandango Questions and Comments 3 01-05-2009 12:01 PM
Image Upload Module -- Call for feature requests cent Questions and Comments 12 11-15-2008 01:13 PM


Pligg Modules and Pligg Templates from Pligg Pro Find support on the Pligg CMS Forum - 24 hours a day! Make a donation to support Pligg CMS development