Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C#
send email in arabic that contain english words will be difficult to read because of the no alignment of the body
how can i make a right to left alignment that will display the english word in the correct place of the body??
Posted 25-Nov-12 23:00pm
Edited 26-Nov-12 1:02am
v2
Comments
Sergey Alexandrovich Kryukov at 26-Nov-12 11:42am
   
How is that related to C#? Mail is mail...
--SA

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

You can freely mix Arabic text with English or any other languages of left-to-right flow direction. This direction actually has nothing to do with alignment.
 
The only problem is editing such texts, because the actual behavior of text caret depends on the character repertoire of the neighboring characters. Even though it almost drove me crazy, in all cases I managed to type required text (anyway, please don't talk to me in Arabic: unfortunately, I cannot understand the language itself, I remember only very few words — I did it only for testing some software Smile | :) ).
 
If you still have any concerns about alignment, you should understand that it has nothing specific to e-mail. Rather, it depends on the content type. Basically, you have a choice from the content type "text/plain" or "text/HTML". In case of plain text, there is nothing like real alignment. Just try to mix the right-to-left and left-to-right text and see how it looks: to me, quite readable and even editable. With HTML, you can control alignment with CSS. When specifying content type, don't forget to specify encoding. Most typically, it should be UTF-8; and this is most advisable, too: "text/plain; charset=utf-8" or "text/html; charset=utf-8".
 
Of course, you always can write multi-part e-mail message, then each part can have its own content type.
 
—SA
  Permalink  
v3

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 428
1 CHill60 310
2 BillWoodruff 183
3 DamithSL 163
4 OriginalGriff 163


Advertise | Privacy | Mobile
Web03 | 2.8.141022.1 | Last Updated 26 Nov 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100