Help for this page

Select Code to Download


  1. or download this
    <?xml version="1.0"?>
    <root xmlns:foo="http://foo"><parent><foo:child/></parent></root>
    
  2. or download this
    use strict;
    use warnings;
    ...
    my $c = $p->addChild(  $d->createElement( q{foo:child} )  );
    
    printf qq{child->prefix=%s, child->localname=%s\n}, $c->prefix, $c->lo
    +calname;
    
  3. or download this
    $c->setAttribute( q{foo:abc}, q{123} );
    my $an = $c->getAttributeNode( q{foo:abc} );
    printf qq{an->prefix=%s, an->name=%s\n}, $an->prefix, $an->name;