The best solution would be to set a standard for your XML and stick to it so that your attributes are all formed consistently. If this is not an option then you could just do multiple searches. Not the prettiest solution but might do the job.
Pass the attribute name as a String
to a method that searches for it in both upper and lower case and returns the combined results.
private function onLoaded(e:Event):void
{
xml = new XML(e.target.data);
var list:XMLList = getNodesByAttribute("att");
trace(list[1]);
}
private function getNodesByAttribute(attributeID:String):XMLList
{
var list:XMLList = (xml..@[attributeID.toLowerCase()]) + (xml..@[attributeID.toUpperCase()]);
return list;
}
If your attributes are not only all upper and all lower case (ATTRIBUTE, attribute AND Attribute) then this will get messy and won't help.
Maybe you could push the idea further using a regular expression but I'm afraid I am no good at regex (not even sure if it can be used in this situation).