Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Brian Huntington
November 5, 2004, 3:13 pm
rate this thread
My XML looks like this:
<!DOCTYPE AGU-article PUBLIC "-//AGU//DTD article AGU DTD version
"http://www.agu.org /[path]/AGU-Article-3.43.dtd" [
<!ENTITY fig01 PUBLIC "etc" "2004gl020054-f01.tif" NDATA tif>
<!ENTITY fig02 PUBLIC "etc" "2004gl020054-f02.tif" NDATA tif>
<!ENTITY fig03 PUBLIC "etc" "2004gl020054-f03.tif" NDATA tif>
Getting the article media file names is easy enough using XML::Parser.
I just create an ENTITY Handler sub and print @_. The problem is
that I intend to use XML::XPath throughout my script, and I'd rather
not waste the memory/time used creating two objects, for $parser and
$xpath. Also note that the script will parse a list of files, maybe
twenty or more. If I could get these filenames using XML::XPath...
well, that would be sweet.
I've checked out the documentation and searched through various
usenet, but haven't found a direct answer.
Any hints would be appreciated.
- » Time::Local V 1.10 and users thereof, eg Archive::Zip V 1.14
- — Previous thread in » PERL Modules Announcements