SitePoint Sponsor

User Tag List

Results 1 to 12 of 12
  1. #1
    SitePoint Enthusiast
    Join Date
    Nov 2011
    Posts
    90
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Is there a way to force UTF8 in a 'mailto' statement

    Hi there,
    I am new in this "Web/HTML" and I was wondering if there is a way to force email client to go in UTF8 mode
    through a 'mailto'.
    Please advice here.

  2. #2
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    23,618
    Mentioned
    413 Post(s)
    Tagged
    7 Thread(s)
    Hi esn003. Welcome to SitePoint.

    Could you say a bit more about what you mean? What is the process you envisage happening?

  3. #3
    SitePoint Enthusiast
    Join Date
    Nov 2011
    Posts
    90
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi Ralph and thanks,
    It is about encoding. Normaly, in my part of the world, email clients like Outlook,
    have as default a specific encoding methode and I need to make it UTF8 in order
    to see the fonts right.
    Any idea? please help me if you can.

  4. #4
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    23,618
    Mentioned
    413 Post(s)
    Tagged
    7 Thread(s)
    Sure, but I still don't know what process you are describing. mailto: is just a way of configuring a link on a web page to open an email client and a new email addressed to the address following "mailto". None of that has any influence on the encoding the email client is using. That's not up to you at all. If you are sending an HTML email, you can of course encode it any way you like.

    Are you asking how to force people who are sending emails to use utf-8? That has nothing to do with web design as such.

    So I'm still not clear on what you are asking. Do you see why?

    EDIT: O, I see you are talking about fonts. Are you asking about how to set up your own email client?

  5. #5
    SitePoint Enthusiast
    Join Date
    Nov 2011
    Posts
    90
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ralph I think that if we'll talk 'code'-ish it will be easier.
    Here is my code:

    <!-- Javascript function for sending register request -->
    <script language="javascript">
    function subscription_request()
    {
    send_it = "mailtoxx@xxx.net.il?subject=~הצטרפות לרשימת תפוצה~&body=&#x202A;שמך המלא בבקשה:%20";
    document.location = send_it;
    }
    </script>
    Last edited by Paul O'B; Nov 4, 2011 at 08:05. Reason: email address removed

  6. #6
    SitePoint Enthusiast
    Join Date
    Nov 2011
    Posts
    90
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Wow Ralph,
    I just red your article "Tips on Character Encoding" on you Web Tips.
    Now I know that you too have a long way behind you on UTF8 and
    I might have some more questions to ask you, like how to force
    the email client to go into 'rtl' in the same mailto.
    It is very instructive reading your site.
    Thanks again.

  7. #7
    Robert Wellock silver trophybronze trophy xhtmlcoder's Avatar
    Join Date
    Apr 2002
    Location
    A Maze of Twisty Little Passages
    Posts
    6,316
    Mentioned
    60 Post(s)
    Tagged
    0 Thread(s)
    It sounded like you were actually wanting to set these values within HTML e-mail documents and in which case apart from the encoding your best bet is to probably use the correct attributes, e.g. <html dir="rtl">

    I guess things like sending: Content-Type: text/plain;charset=UTF-8 would effect the encoding. Though I don't have any "real world" familiarity with such e-mail templates or actual mail client markup regarding standards support relational to this type of question.

    However, I assume the main page containing the email link itself would already be in Hebrew in which case similar applies. See: http://www.w3.org/International/tutorials/bidi-xhtml/

  8. #8
    SitePoint Enthusiast
    Join Date
    Nov 2011
    Posts
    90
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi xhtmlcoder,
    My point is that the 'mailto' above should be independent of one person's browser
    or email client software and once and only once (for this email) set the proper
    characteristics in order to see it right.
    My browser is set OK and so is the code but, when others send it looks BAD!
    Any ideas?

  9. #9
    Robert Wellock silver trophybronze trophy xhtmlcoder's Avatar
    Join Date
    Apr 2002
    Location
    A Maze of Twisty Little Passages
    Posts
    6,316
    Mentioned
    60 Post(s)
    Tagged
    0 Thread(s)
    It might be a limitation of functionally in mailto: protocol in a page, since you cannot dictate what mail client the user has installed or how it is configured. That protocol doesn't really have strictly defined standards regarding the other values for headers either. All you really can do is make sure the page headers itself are all correct and the encodings.

    The rest is out of your hands basically if it doesn't fall within US-ASCII and hence why server-side mail forms tend to be more popular - apart from the spambot issue.

  10. #10
    SitePoint Enthusiast
    Join Date
    Nov 2011
    Posts
    90
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thank you xhtmlcoder. I don't like it but I have to accept it.
    In my code above you can see kind of control characters like "&#x202A;".
    Do you know where can I find more data of this kind?

  11. #11
    Robert Wellock silver trophybronze trophy xhtmlcoder's Avatar
    Join Date
    Apr 2002
    Location
    A Maze of Twisty Little Passages
    Posts
    6,316
    Mentioned
    60 Post(s)
    Tagged
    0 Thread(s)

  12. #12
    SitePoint Enthusiast
    Join Date
    Nov 2011
    Posts
    90
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thank you again xhtmlcoder. This brought me a little bit closer to what I need.


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
  •