Help with arabic language

Ask a Question related to PHP Development, Design and Development.

  1. #1

    Default Re: Help with arabic language

    Hello Andy

    Adding this header worked also with edit boxes.

    One more question, will the data always be stored in the database as:
    > >اثممخ صخقمي
    Why not as ascii characters like when you save a file in notepad/utf-8
    and then hexview it?

    --
    Elias
    lallous Guest

  2. Similar Questions and Discussions

    1. Arabic language
      Is there any way to work with arabic language in InDesign CS? I need sometimes to write text in arabic and I HATE to do it in MS Word or (even...
    2. how to embed arabic fonts in director so that arabic texts will be shown
      how to embed arabic fonts in director so that arabic texts will be shown normally in their format not in symbols
    3. #25051 [Opn->WFx]: translating between gettext language identifiers and 'Accept-Language' ones
      ID: 25051 Updated by: sniper@php.net Reported By: wouter at grep dot be -Status: Open +Status: Wont...
    4. How to prevent the language icon from disappearing and a language switching delay?
      What is wrong with my question since nobody answers it? How to improve the question? "Dmitriy Kopnichev" <kopn@hotbox.ru> wrote in message...
    5. Language and Direction real GURU needed! (Hebrew and maybe arabic) CR or Charset issue?
      Hello all! I wonder if the following subject is a Crystal issue or what? When ever I have a field that includes hebrew(-RTL language) and numbers...
  3. #2

    Default Re: Help with arabic language

    On 1 Apr 2004 21:07:54 -0800, [email]lallous@lgwm.org[/email] (lallous) wrote:
    >Adding this header worked also with edit boxes.
    >
    >One more question, will the data always be stored in the database as:
    >> >اثممخ صخقمي
    >Why not as ascii characters like when you save a file in notepad/utf-8
    >and then hexview it?
    No, not if you've set the headers correctly so that the browser sends UTF-8 in
    the first place, rather than trying to send HTML encoded character entities
    because they're not available in the HTML document's character set.

    e.g. the following:

    <?php header("Content-type: text/html;charset=utf-8"); ?>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <title>test</title>
    </head>
    <body>
    <form method="post" action="">
    <input type="text" name="whatever">
    <input type="submit">
    </form>
    <pre>
    <?php
    if (isset($_POST['whatever']))
    {
    var_dump($_POST['whatever']);
    for ($i=0; $i<strlen($_POST['whatever']); $i++)
    {
    $c = ord($_POST['whatever']{$i});
    printf("%-3d %08b<br>", $c, $c);
    }
    }
    ?>
    </pre>
    </body>
    </html>

    Post some Unicode to this, and you can see that it's not HTML encoded it.

    --
    Andy Hassall <andy@andyh.co.uk> / Space: disk usage analysis tool
    [url]http://www.andyh.co.uk[/url] / [url]http://www.andyhsoftware.co.uk/space[/url]
    Andy Hassall Guest

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139