Jump to:

17452 Posts in 4473 Topics by 1971 members

Archive

SilverStripe Forums » Archive » Email encoding iso8859-2

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

Page: 1
Go to End
Author Topic: 2591 Views
  • karibe
    Avatar
    Community Member
    56 Posts

    Email encoding iso8859-2 Link to this post

    Hello

    I have problems to encode contact form emails into my country iso2

    Thunderbird shows iso8859-15(sic!)

    How to set my iso8859-2

    in my class that extends UserDefinedForm_Controller
    ...
    private function encode( $submitedFields )
    {
          while ($submitedFields->next())
          {
             $submitedFields->current()->Title = iconv( "utf-8", "iso8859-2", $submitedFields->current()->Title );
             $submitedFields->current()->Value = iconv( "utf-8", "iso8859-2", $submitedFields->current()->Value );
          }
          
          return $submitedFields;
    }
    ...

  • dio5
    Avatar
    Community Member
    501 Posts

    Re: Email encoding iso8859-2 Link to this post

    Hi,

    I've had some troubles with emails too and solved it by changing all the charsets in
    sapphire/core/Email.php from

    iso-8859-15

    to

    utf-8

    I think it's at about 5 or 6 places in that file that you can replace it.

    Hope that helps.

  • karibe
    Avatar
    Community Member
    56 Posts

    Re: Email encoding iso8859-2 Link to this post

    Thanks it working...

  • Tim
    Avatar
    Core Development Team
    201 Posts

    Re: Email encoding iso8859-2 Link to this post

    I've reported this in the issue tracker @ http://open.silverstripe.com/ticket/2176

    2591 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.