Ticket #1484926 (closed Bugs: duplicate)

Opened 10 months ago

Last modified 5 months ago

Sending attachments not working (MIME/file types)

Reported by: jharris3434 Owned by:
Priority: 5 Milestone: later
Component: Client Scripts Version: 0.1-stable
Severity: normal Keywords:
Cc:

Description

RC 0.1 Stable, PHP 5.2.5, MySQL 5, hMailServer, and IIS6 on W2K3 server. Using Firefox 2.0.0.12

I should note first that RC is handling attachments sent with other mail clients perfectly.

When I upload/send pattachments with RC, however, RC isn't handling them properly at all. I have set the attachment and memory limits up, I've made sure the temp directory has the proer permissions. Most of the time the attachment does get attached.

The main problem, however, is that it doesn't seem to be recognizing/packaging filetypes correctly. The only attachment type it does handle correctly is .txt. PDFs, images, etc do get attached, but when they're viewed with a different mail client, such as Thunderbird, they usually come up attached as .txt, regardless of what they are, with the resultant gibberish. When viewed from RC they show up in unpredictable ways, and certainly don't open properly.

There are no errors in the logs.

I've attached a couple of different files of different types for testing purposes.

Attachments

TestRC_[doc].doc (23.5 kB) - added by jharris3434 10 months ago.
TestRC_[jpg].jpg (67.9 kB) - added by jharris3434 10 months ago.
TestRC_[pdf].pdf (4.9 kB) - added by jharris3434 10 months ago.
TEST.doc (108.8 kB) - added by zeno.popovici 10 months ago.
Garbled Result

Change History

Changed 10 months ago by jharris3434

Changed 10 months ago by jharris3434

Changed 10 months ago by jharris3434

  Changed 10 months ago by jharris3434

This should be in milestone 0.1.1.

follow-up: ↓ 3   Changed 10 months ago by francesco_r

I have had the same problem (see ticket #1484887) but using Centos Linux. I have resolved changing the path of mime_magic in main.inc.php. For example rc default is: $rcmail_configmime_magic? = '/usr/share/misc/magic'; and i changed in: $rcmail_configmime_magic? = '/usr/share/file/magic.mime';

in reply to: ↑ 2 ; follow-up: ↓ 5   Changed 10 months ago by jharris3434

Replying to francesco_r:

I have had the same problem (see ticket #1484887) but using Centos Linux. I have resolved changing the path of mime_magic in main.inc.php. For example rc default is: $rcmail_configmime_magic? = '/usr/share/misc/magic'; and i changed in: $rcmail_configmime_magic? = '/usr/share/file/magic.mime';

This did not work for me.

Changed 10 months ago by zeno.popovici

Garbled Result

  Changed 10 months ago by zeno.popovici

I have the very same problem. Files get corrupted when sent from RC Mail. There are no problems when receiving attachments from other mail clients.

in reply to: ↑ 3 ; follow-up: ↓ 7   Changed 10 months ago by francesco_r

Replying to jharris3434:

Replying to francesco_r:

I have had the same problem (see ticket #1484887) but using Centos Linux. I have resolved changing the path of mime_magic in main.inc.php. For example rc default is: $rcmail_configmime_magic? = '/usr/share/misc/magic'; and i changed in: $rcmail_configmime_magic? = '/usr/share/file/magic.mime';

This did not work for me.

Did you set the correct path for windows? my example is for linux, not windows. So you must set the correct directory and magic file of your apache installation.

  Changed 10 months ago by rosali

Seems to be the same issue as my ticket #1484914 (including an approache to solve it)

...

in reply to: ↑ 5   Changed 10 months ago by jharris3434

Replying to francesco_r:

Replying to jharris3434:

Replying to francesco_r:

I have had the same problem (see ticket #1484887) but using Centos Linux. I have resolved changing the path of mime_magic in main.inc.php. For example rc default is: $rcmail_configmime_magic? = '/usr/share/misc/magic'; and i changed in: $rcmail_configmime_magic? = '/usr/share/file/magic.mime';

This did not work for me.

Did you set the correct path for windows? my example is for linux, not windows. So you must set the correct directory and magic file of your apache installation.

Here is what I did. First, I followed these instructions to make sure fileinfo() was working correctly with magic.mime:

http://kpable.com.au/index.php/20070715/using-fileinfo-functions/

Using that little PHP script with my setup is showing me that indeed, everything is working. In my main.inc.php, I changed the variable to:

$rcmail_config['mime_magic'] = 'C:\PHP\extras\magic\magic.mime';

(That directory has read & execute permissions for IIS, which I think should be enough.)

It's not working properly. To clarify: Thunderbird isn't understanding the attachments that RC sends. RC is sort of understanding the attachments RC sends. (RC understands the attachments other mail programs send perfectly.) I'll enumerate them here:

Attachments sent with RC, opened in Thunderbird
PDFs show up attached, and email body is shown, but Thunderbird thinks the file type is TXT. JPGs and DOCs aren't showing up at all, neither does the text in the body of the email. Thunderbird is showing the size of the email properly.

Attachments sent with RC, opened in RC
All attachment filetypes are showing up properly, but RC isn't opening them up in the 'native' viewer like it does for attachments that are handled properly (i.e. sent from Thunderbird), it just prompts for download. The files are uncorrupted when downloaded.

I hope this helps clarify a little.

  Changed 7 months ago by till

  • status changed from new to closed
  • resolution set to duplicate

Continue here: #1484973

Note: See TracTickets for help on using tickets.