Results 1 to 5 of 5

Thread: Using an e-mail form, danish characters are not reproduced

  1. #1
    Join Date
    Aug 2007
    Location
    Copenhagen, Denmark
    Posts
    9
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Question Using an e-mail form, danish characters are not reproduced

    Hello.

    I have constructed a page with form fields. These fields are connected to a php-page, sending an e-mail with the information given in the form fields. The mail arrives, but the danish letters æ (&aelig ø (&oslash and å (&aring turns up as different, strange characters.
    I have tried to change the specific letter to the code (trying first æ then &#230 without success - I thought it would suffice incerting the actual code, but it doesn't.
    I use DreamWeaver CS3, if this information helps.

    Thanks for any help.
    Kim

  2. #2
    Join Date
    Jan 2008
    Posts
    4,168
    Thanks
    28
    Thanked 628 Times in 624 Posts
    Blog Entries
    1

    Default

    Well, its most likely because the way your header in your email is set, can you please share your code so we can help you?
    Jeremy | jfein.net

  3. #3
    Join Date
    Aug 2007
    Location
    Copenhagen, Denmark
    Posts
    9
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default

    Hello Nile.

    Here comes the code:

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Mailform</title>
    </head>

    <body>

    <?php
    print "<br><br><br>Kære $_POST[name_your]";
    print "<br><br>Din anbefaling er sendt til $_POST[name_friend].<br><br>";
    print "Tak fordi du har ønsket at anbefale os.<br><br>";
    print "Med venlig hilsen <br> Life & Body Balance";


    $msg = "\nKære $_POST[name_friend]";
    $msg .= "\n\n På $_POST[name_your]'s foranledning inviterer vi dig til at besøge vor side - måske er vort koncept lige det du søger......\n\n";
    $msg .= "<www.lifebodybalance.dk>";
    $msg .= "\n\n Med venlig hilsen \n Life & Body Balance";

    $recipient = "$_POST[mail_friend]";
    $subject = "En ven anbefaler dig denne side";

    mail($recipient, $subject, $msg);
    ?>

    </body>

  4. #4
    Join Date
    Jan 2008
    Posts
    4,168
    Thanks
    28
    Thanked 628 Times in 624 Posts
    Blog Entries
    1

    Default

    I suggest you looking at this:
    http://us2.php.net/mb_send_mail#pagefooter
    Quote Originally Posted by Php.net
    You could send Thai, Chinese, and Danish characters in the same message.
    Jeremy | jfein.net

  5. The Following User Says Thank You to Nile For This Useful Post:

    SPOKMIK (04-08-2008)

  6. #5
    Join Date
    Aug 2007
    Location
    Copenhagen, Denmark
    Posts
    9
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default

    I have now found the answer. For everybody's information the solution is:

    change
    from: <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    to: <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />

    thanks to everyone for the help.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •