var attrs:XMLList = sameXML.@*; var tempAttrName:String; for each (var attrItem:XML in attrs) { tempAttrName = attrItem.name(); }