1

I'm using MS SQL database item master. The cdescription column is nvarchar data type and display the Arabic encoding when executing a select or view query.

In writing the item master to xml file I'm using DOMDocument::createElement. The xml file is encoded in utf-8 and version 1.0.

$dom = new DOMDocument();

$dom->encoding = 'utf-8';
$dom->xmlVersion = '1.0';
$dom->formatOutput = true;    
...
$LineName   = $dom->createElement('cbc:Name', $row['cDescription']); 
$LineItem->appendChild($LineName);  //LineName end  

However the Arabic values are being replaced with ????? ???? characters.

0 Answers0