[Xml-compile] XML to parse does not contain a namespace
Mark Overmeer
mark at overmeer.net
Wed Nov 14 10:20:27 GMT 2012
* Karen Etheridge (perl at froods.org) [121113 19:03]:
> On Sun, Nov 11, 2012 at 11:37:18PM +0100, Mark Overmeer wrote:
> > Many abuse namespaces.
> > What about overruling the form?
> >
> > my $schema = XML::Compile::Cache->new($xsdfn
> > , element_form_default => 'unqualified');
>
> That doesn't seem sufficient.
Ah. Yes... this only changes the definition, not the usage of the
namespace.
> my $schema = XML::Compile::Cache->new(
> $xsd,
> # this doesn't help either
> # target_namespace => '',
> element_form_default => 'unqualified',
> );
>
> my $reader = $schema->compile(
> READER => pack_type('http://www.w3schools.com', 'Foo'),
>
> # including these bits doesn't help either
> key_rewrite => 'PREFIXED',
> prefixes => [
> 'http://www.w3schools.com' => '',
> ],
> );
I forgot how to do it.
my $schema = XML::Compile::Cache->new($xsd);
my $reader = $schema->compile
( READER => pack_type('http://www.w3schools.com', 'Foo'),
, elements_qualified => 'NONE'
);
--
Regards,
MarkOv
------------------------------------------------------------------------
Mark Overmeer MSc MARKOV Solutions
Mark at Overmeer.net solutions at overmeer.net
http://Mark.Overmeer.net http://solutions.overmeer.net
More information about the Xml-compile
mailing list