Converting PHP to unicode (UTF-8) format
Posted: Mon Sep 11, 2006 9:34 pm
Hi, I'm using the following PHP code to retrieve and print text from a mysql database. I have created a Flash movie that retrieves the text generated by this PHP file and displays it. For some reason some of the characters visible in the PHP file are invisible in the Flash movie, such as the characters '+' and '€'. I have spoken to a Flash expert about this and he suggested encoding my PHP file as unicode (UTF-8) format as Flash prefers this. Do you know how I can do this?
Thank you,
Leao
Thank you,
Leao
Code: Select all
<?php
mysql_connect("mysql.myurl.com","username","password") or die(mysql_error());
mysql_select_db("username_database") or die(mysql_error());
$result = mysql_query("SELECT * FROM database")
or die(mysql_error());
$row = mysql_fetch_array( $result );
echo $row['landline'];
?>