CHARSET (PHP & MySQL)

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

    #1

    CHARSET (PHP & MySQL)

    Hi! I saw that there was some writing about it but nothing helps

    I have hosting in some firm in US. I set ma database charset to
    windows-1250. I also set all tables to that charset. Insert with phpmyadmin
    works fine but when I use php, as output I get strance chars.

    When I use php to enter data insted of special chars I get "?" or none.

    Its strange for me becuase when I use SQL trough phpmyadmin and execute
    script that insert rows all data are inserdet right!

    Do I need and can it be done to setup charset for PHP. I dont have admin
    privilegies on server :)

    Please help!



  • deresh

    #2
    Re: CHARSET (PHP & MySQL)

    On Sat, 19 Mar 2005 02:03:56 +0100, Bubbi wrote:
    [color=blue]
    > Hi! I saw that there was some writing about it but nothing helps
    >
    > I have hosting in some firm in US. I set ma database charset to
    > windows-1250. I also set all tables to that charset. Insert with phpmyadmin
    > works fine but when I use php, as output I get strance chars.
    >
    > When I use php to enter data insted of special chars I get "?" or none.
    >
    > Its strange for me becuase when I use SQL trough phpmyadmin and execute
    > script that insert rows all data are inserdet right!
    >
    > Do I need and can it be done to setup charset for PHP. I dont have admin
    > privilegies on server :)
    >
    > Please help![/color]

    after establising connection to server execute this query:

    SET NAMES windows-1250;

    this should help


    kreso@REMOVEwil levolve.com





    Comment

    Working...