>> var a:XMLList = new XMLList(
>> '<?xml-stylesheet href="my.css" type="text/css"?>' +
>> '<root xmlns="http://example.com/" xmlns:id="wtf" />');
>> var b:XML = a[1];
>> trace(b.namespaceDeclarations()); //wtf
>> trace(b.namespace()); //http://example.com/
>> namespaceDeclarations() gets the namespaces the node defines, and
>> namespace() gets the namespace the node is in. You can see that the
>> processing instruction has no impact on whether this works.
>
> Shouldn't b.namespaceDeclarations() also include the default namespace
> declaration (xmlns="http://example.com/"), or does that get stripped out
> because it's already accessible via b.namespace()?
XML.ignoreProcessingInstructions = false;
var a:XML = new XML(
'<?xml-stylesheet href="my.css" type="text/css"?>' +
'<root xmlns="http://example.com/" xml:id="wtf" />');
trace(a.namespaceDeclarations());
When i use XML, namespaceDeclarations() contains the default
declaration. When i use XMLList as in the example above, it doesn't.
Cheers,
Claus.
--
claus wahlers
cĂ´deazur brasil
http://codeazur.com.br/
http://wahlers.com.br/claus/blog/
--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/