Passei por um problema semelhante a esse a um tempo atrás, consegui resolver... Mais esse ainda não entendi como! O codigo abaixo popula uma combo através de uma XML... Até ai tranquilo, porem os itens da combo que contém "&", aparecem "%26"... Achei uma função que substitui isso, mais não estou sabendo usa-la, deem uma olhada!
CÓDIGO
//Popula combo
var xmllojas:XML = new XML();
xmllojas.ignoreWhite = true;
xmllojas.load("....xml.php");
xmllojas.onLoad = function() {
xmlobj.loaded = true;
xmlobj.onload(true);
var alistalojas:Array = new Array();
alistalojas.push({label:"escolha uma loja"});
for (var i = 0; i<xmllojas.childNodes[0].childNodes.length; i++) {
alistalojas.push({label:xmllojas.firstChild.childNodes[i].childNodes[1].firstChild.nodeValue});
}
comboloja.dataProvider = alistalojas;
};
var xmllojas:XML = new XML();
xmllojas.ignoreWhite = true;
xmllojas.load("....xml.php");
xmllojas.onLoad = function() {
xmlobj.loaded = true;
xmlobj.onload(true);
var alistalojas:Array = new Array();
alistalojas.push({label:"escolha uma loja"});
for (var i = 0; i<xmllojas.childNodes[0].childNodes.length; i++) {
alistalojas.push({label:xmllojas.firstChild.childNodes[i].childNodes[1].firstChild.nodeValue});
}
comboloja.dataProvider = alistalojas;
};
CÓDIGO
//Função
String.prototype.replace = function(text, substituirtexto) {
return this.split(text).join(substituirtexto);
//E se chama assim:
//"variavel".replace("&", "%26")
};
String.prototype.replace = function(text, substituirtexto) {
return this.split(text).join(substituirtexto);
//E se chama assim:
//"variavel".replace("&", "%26")
};
Vlw galera!

Help














