# Special character problem as3 with php/xml

**URL:** https://forum.kirupa.com/t/special-character-problem-as3-with-php-xml/320020
**Category:** flash
**Created:** [March 11, 2011, 2:22pm UTC](https://forum.kirupa.com/t/special-character-problem-as3-with-php-xml/320020 "2011-03-11T14:22:28Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![neroneelfico](https://avatars.discourse-cdn.com/v4/letter/n/76d3ee/32.png) [@neroneelfico](https://forum.kirupa.com/u/neroneelfico)
#### Post date: [March 11, 2011, 2:22pm UTC](https://forum.kirupa.com/t/special-character-problem-as3-with-php-xml/320020/1 "2011-03-11T14:22:28Z")

</div>

Hi, I have a problem to see special characters (like "è,ò,ì…I see Ã¨), in flash when I load them from sql with php and xml.  
Here my scripts:

AS3:

```auto
var myDomandaXML:XML = new XML();
var varDomande:URLRequest = new URLRequest(MyGlobal.LinkDomande);
varDomande.method = URLRequestMethod.POST;
var varLoaderDom:URLLoader = new URLLoader ;
varLoaderDom.dataFormat = URLLoaderDataFormat.VARIABLES;
varLoaderDom.addEventListener(Event.COMPLETE, processDATIDom);
varLoaderDom.load(varDomande);

function processDATIDom(e:Event):void
{
    var myDomandaXML = e.target.data;
    myDomandaXML = unescape(myDomandaXML);
    myDomandaXML = new XML(myDomandaXML);
    // I tried to use this too 
        //myDomandaXML.useCodePage=true;
    Domanda.text = myDomandaXML.DOMANDA;

```

PHP:

```auto
<?php
header("Content-Type: application/x-javascript; charset=ISO-8859-1");
#Include accesso a database
include_once "../config.php";
include "../query.php";

$query = mysql_query("SELECT * FROM domande WHERE ID = 1);
$row = mysql_fetch_array( $query );
        echo "<?xml version =\"1.0\" encoding =\"UTF-8\"?>
";
        echo "<TABELLA>
";
    echo "<DOMANDA>".$row['domanda']."</DOMANDA>
";
    echo "</TABELLA>
";
?>

```

I wrote in “row ‘domanda’” in database directly(just some example), collation is set to latin1\_swedish\_ci.

I tried to open php directly and I see characters correctly “è,ù” but in flash no…why? I’m going crazy…really…:s
