Changeset 18900


Ignore:
Timestamp:
2009-04-06T14:41:54+12:00 (15 years ago)
Author:
kjdon
Message:

this relied on the fact that the parser created in ReadXMLFile strips out namepsaces. It no longer does this, so now we need to create our own xml parser that does do it.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • gsdl/trunk/perllib/plugins/MARCXMLPlugin.pm

    r18563 r18900  
    6767
    6868    my $self = new ReadXMLFile($pluginlist, $inputargs, $hashArgOptLists);
    69    
     69       
     70    # we want to strip namespaces, so have to create a new XML parser
     71    my $parser = new XML::Parser('Style' => 'Stream',
     72                                 'Pkg' => 'ReadXMLFile',
     73                                 'PluginObj' => $self,
     74                 'Namespaces' => 1, # strip out namespaces
     75                 'Handlers' => {'Char' => \&ReadXMLFile::Char,
     76                        'XMLDecl' => \&ReadXMLFile::XMLDecl,
     77                        'Entity'  => \&ReadXMLFile::Entity,
     78                        'Doctype' => \&ReadXMLFile::Doctype,
     79                        'Default' => \&ReadXMLFile::Default
     80                                 });
     81
     82    $self->{'parser'} = $parser;
     83
    7084    $self->{'content'} = "";
    7185    $self->{'xmlcontent'} = "";
Note: See TracChangeset for help on using the changeset viewer.