php displays dBase table with wrong charset!

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

    php displays dBase table with wrong charset!

    Hi!

    I read an dBase table under Win XP by the common dBase functions of PHP
    4.3.5.
    But all records are displayd with a wrong charset.
    All umlauts of the databasefile like "öäüéô"... and so on are not
    displayed or are displayed in a wrong way! :-(

    How can I set the correct charset for the table, that all umlauts keep save?

    I thank you so much for your answer,
    Lars
  • DH

    #2
    Re: php displays dBase table with wrong charset!

    Goldfisch1980 wrote:[color=blue]
    > Hi!
    >
    > I read an dBase table under Win XP by the common dBase functions of PHP
    > 4.3.5.
    > But all records are displayd with a wrong charset.
    > All umlauts of the databasefile like "öäüéô"... and so on are not
    > displayed or are displayed in a wrong way! :-(
    >
    > How can I set the correct charset for the table, that all umlauts keep
    > save?
    >
    > I thank you so much for your answer,
    > Lars[/color]

    You may, or may not, find helpful info here:

    Comment

    • Tony Marston

      #3
      Re: php displays dBase table with wrong charset!

      You need to change the default charset that PHP uses.

      (a) In your php.ini file change this line: default_charset = "UTF-8"
      or
      (b) In your .htaccess file set this line: php_value default_charset "UTF-8"

      You must also ensure that your HTML output is UTF-8, so issue this command
      before you output anything:
      header('content-type:text/html; charset=UTF-8');

      Hope this helps.


      --
      Tony Marston

      This is Tony Marston's web site, containing personal information plus pages devoted to the Uniface 4GL development language, XML and XSL, PHP and MySQL, and a bit of COBOL




      "DH" <doug861@comcas t.net> wrote in message
      news:dI-dnZ9h_soDa5DfRV n-ow@comcast.com. ..[color=blue]
      > Goldfisch1980 wrote:[color=green]
      >> Hi!
      >>
      >> I read an dBase table under Win XP by the common dBase functions of PHP
      >> 4.3.5.
      >> But all records are displayd with a wrong charset.
      >> All umlauts of the databasefile like "öäüéô"... and so on are not
      >> displayed or are displayed in a wrong way! :-(
      >>
      >> How can I set the correct charset for the table, that all umlauts keep
      >> save?
      >>
      >> I thank you so much for your answer,
      >> Lars[/color]
      >
      > You may, or may not, find helpful info here:
      > http://www.dbtools.com.br/EN/article.php?id=00043[/color]


      Comment

      Working...