How to display arabic characters in web page using php and sql server

后端 未结 3 1082
情歌与酒
情歌与酒 2021-01-25 09:27

How can I display Arabic characters in web page using php and sql server? The Arabic data is stored in the database (sql server). Now I want to use php to display that data on t

3条回答
  •  梦谈多话
    2021-01-25 10:09

    Note: its php/mysql based example:

    1. Before you can store Arabic content in a database, you need to create a table. The following example demonstrates the CREATE syntax
    2. You need to make sure your browser supports the character set.

    SQL Statements:

    //assumed : connection to the database is open
    mysql_query("SET CHARACTER SET utf8");
    mysql_query("SET NAMES 'utf8'");
    // select records
    mysql_query("SELECT * FROM en_authors");
    

提交回复
热议问题