accent problem with é è à ù

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • JB

    accent problem with é è à ù

    Hi,

    I'm having a problem with accent in PHP/HTML.

    I have a value stored in a table.
    The value is : é è à ù
    When I look directly into table via phpmyadmin, the value seems to be
    stored correctly.
    Yet, when I try to get the value in my php code (mysql_query() ... ),
    what I get is totally different for the three lasts characters.

    I get the 'é' correctly, but the other characters are transformed into
    special characters : a 'c' with a special accent: an inverted ^ ), an
    'r' with an accent, and a 'u' with a square on top of it.

    I tried to use addslashes() or stripslashes() but it didn't changed
    the problem at all.

    Does anybody have any idea about what is happening?

    Thanks.

    JB isnardon
  • Bruno Desthuilliers

    #2
    Re: accent problem with é è à ù

    JB wrote:[color=blue]
    > Hi,
    >
    > I'm having a problem with accent in PHP/HTML.
    >
    > I have a value stored in a table.
    > The value is : é è à ù
    > When I look directly into table via phpmyadmin, the value seems to be
    > stored correctly.
    > Yet, when I try to get the value in my php code (mysql_query() ... ),
    > what I get is totally different for the three lasts characters.
    >
    > I get the 'é' correctly, but the other characters are transformed into
    > special characters : a 'c' with a special accent: an inverted ^ ), an
    > 'r' with an accent, and a 'u' with a square on top of it.
    >
    > I tried to use addslashes() or stripslashes() but it didn't changed
    > the problem at all.
    >
    > Does anybody have any idea about what is happening?[/color]

    Probably a problem with character encoding in the html page that
    displays the results...

    My 2 cents
    Bruno

    Comment

    • somaBoy MX

      #3
      Re: accent problem with é è à ù


      "JB" <jeanbaptiste_i snardon@yahoo.f r> wrote ...
      : I get the 'é' correctly, but the other characters are transformed into
      : special characters : a 'c' with a special accent: an inverted ^ ), an
      : 'r' with an accent, and a 'u' with a square on top of it.
      :
      : I tried to use addslashes() or stripslashes() but it didn't changed
      : the problem at all.
      :
      : Does anybody have any idea about what is happening?

      Try:

      $string = "\* your query result here *\";
      echo utf8_encode($st ring);

      It might just do the trick.


      ..soma


      Comment

      Working...