JPG images posted by mail through popfetcher plugin

Discussion corner for Developers of Serendipity.
Post Reply
maria
Regular
Posts: 28
Joined: Mon Jan 01, 2007 10:51 pm

JPG images posted by mail through popfetcher plugin

Post by maria »

I'm using Serendipity with "popfetcher" plugin in order to send messages by mail.
It's working properly, but I've noted now that when I try to send a image with jpg extension attached to the mail, the image is posted in the Blog as a combo saying:

X Click for full size image

Is there a possibility to have the title of the image instead this combo?
In fact, when I click on the combo the image can be viewed properly.

Thanks a lot for your suggestions.
Maria
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: JPG images posted by mail through popfetcher plugin

Post by garvinhicking »

Hi!

You could edit your serendipity_event_popfetcher.php file and replace this:

Code: Select all

$attlink = '<a class="popfetcherimage" href="' . $serendipity['serendipityHTTPPath'].$serendipity['uploadHTTPPath'].$maildir.$filename.'" target="_blank"><img src="'.$serendipity['serendipityHTTPPath'].$serendipity['uploadPath'].$maildir.$thumbname.'" alt="'.MF_MSG18.'" /></a>';
with this:

Code: Select all

$attlink = '<a class="popfetcherimage" href="' . $serendipity['serendipityHTTPPath'].$serendipity['uploadHTTPPath'].$maildir.$filename.'" target="_blank"><img src="'.$serendipity['serendipityHTTPPath'].$serendipity['uploadPath'].$maildir.$thumbname.'" alt="'.$filename.'" /></a>';
However, the cause of this more likely seems to be that a thumbnail image could not be created on your installation. Does thumbnail creation work if you upload images into the mediadatabase?

Did you configure s9y to use imagemagick? If so, are you sure imagemagick is available? If not, PHP needs to have the GD library compiled in. Otherwise no thumbnails can be created, which could lead to your problem that no thumbnails are displayed.

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
maria
Regular
Posts: 28
Joined: Mon Jan 01, 2007 10:51 pm

thumbnail

Post by maria »

The Thumbnail seems to be working, does it?
I've done a "Rebuild Thumbs", this is the result:

Synchronizing the database with the image folder


Found new/modified file: archives/731.gif.
Found new/modified file: archives/cygcharset-12.dll.
Skipping file: .empty not readable.
Skipping file: 0000log.txt not readable.
Done (Synchronized 2 images).
Resizing


Using archives/731.gif as its own thumbnail because it is so small already.
Done (resized 1 images).


And for one image, if I do a resize, it is viewed as: Orig.: 18x20, Thumb: 18x20

Can we say that thumbnail is working well?

I don't remember the configuration of s9y with imagemagick, and I think that is not available. Is there any way to test it?

So, you say that PHP needs to have the GD library compiled in. How can I test it?

Sorry for my poor knowledge about all the system, but I'm very new in it...
And thanks again and again!!
Best regards,

Maria
maria
Regular
Posts: 28
Joined: Mon Jan 01, 2007 10:51 pm

serendipity_event_popfetcher.php file

Post by maria »

Changes in the serendipity_event_popfetcher.php file:

$filename instead of MF_MSG18 do that the file attached appears with its name.

But it appear with a combo and a X inside, is it correct?

THANKS,

Maria
maria
Regular
Posts: 28
Joined: Mon Jan 01, 2007 10:51 pm

Administration-Configuration Image Conversion Settings

Post by maria »

I've look in my Administration-Configuration menu of my blog:

Image Conversion Settings

Enter general information about how serendipity should handle Images
Use ImageMagick

Do you have ImageMagick installed and want to use it to resize images? No

Path to convert binary
Full path & name of your ImageMagick convert binary
/usr/local/bin/convert

Thumbnail suffix
Thumbnails will be named with the following format: original.[suffix].ext
serendipityThumb

Thumbnail dimensions
Static maximum width of auto-generated thumbnails
110
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Administration-Configuration Image Conversion Settings

Post by garvinhicking »

Hi!

Does your PHP then have the "GD Library" compiled in? You can see it in the output of a <?php phpinfo(); ?> script, or you can ask your admin of your server?

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
maria
Regular
Posts: 28
Joined: Mon Jan 01, 2007 10:51 pm

GD library

Post by maria »

You are rigth Garvin!! My PHP doesn't have the "GD Library" compiled in.
It will be necessary to recompile the PHP.
THANKS!!
Post Reply