Ask not what osTicket community can do for you - ask what you can do for osTicket community

Go Back   osTicket Forums > Project Tools > osTicket Bug Tracker > Bug

Issue Type Bug   Project osTicket Bug Tracker
failure in encoding email body to UTF-8
incoming Email is not encoded to UTF-8
Category Unknown
Affected Version 1.6.0 rc3
Priority 5 - Medium
Status Fixed
Fixed Version 1.6 rc4
Submitted 01-30-2008
Assigned Users (none) Tags (none)

issueid=38 01-30-2008 01:51 AM
Junior Member
failure in encoding email body to UTF-8
incoming Email is not encoded to UTF-8

When receiving an Email with osTicket 1.6 RC3 in any other charset then utf8 osTicket saves the body in it's original charset and not utf8.
Because of that special characters will not be displayed correctly in the web.

I had to edit the following in /include/class.pop3.php:

Code:
$var['message']=Format::stripEmptyLines(utf8_encode($this->getBody($mid)));
Reply

02-04-2008 10:53 AM
Developer
 
For the correct solutions edit class.pop3.php and make the changes below in getPart function.

Change
PHP Code:
if($encoding && 0) { //Convert text to desired mime encoding... 
to
PHP Code:
if($encoding) { //Convert text to desired mime encoding... 
Reply
02-10-2008 11:09 AM
Junior Member
 
Will this error is corrected in version 1.6 Final?
Reply
02-10-2008 08:00 PM
Member
 
the imap_utf8 function works for me.

class.pop3.php, line 209:
Code:
$var['message']=Format::stripEmptyLines(imap_utf8($this->getBody($mid)));
Edit: Please also take a look here, this fixes UTF8 encoding in the database *thanks mrdebian*
Reply
02-15-2008 03:14 PM
Junior Member
 
What if I'm using piping method?

Thank you for your help,
Raffy
Reply
02-18-2008 12:28 PM
Junior Member
 
Hello, I'm not using pop3, but piping.

Can you help me- What shall I have to change for solving problems with accented characters (foreign chars) inside emails?
Thank you in advance for your help,
Raffy
Reply
02-19-2008 05:53 AM
Junior Member
 
Although not a proper solution, you can change the last line of the function getBody in class.mailparse.php from return $body to return utf8_encode($body). This works with piping
Reply
04-06-2008 04:20 PM
Junior Member
 
hi,
see complete fix for utf8 languages

i hope this fix help you
Reply

Issue Tools
Subscribe to this issue

All times are GMT -4. The time now is 11:46 PM.