- From: Hugo Haas <hugo@dev.w3.org>
- Date: Fri, 30 Jul 2004 08:51:19 +0000
- To: public-ws-desc-eds@w3.org
Update of /sources/public/2002/ws/desc/tools In directory homer:/tmp/cvs-serv14835 Added Files: prevloc Log Message: Give the URL of the previous location --- NEW FILE: prevloc --- #!/usr/bin/perl -w # # Give the URL of the previous location use strict; use XML::DOM; my $file = $ARGV[0] || die; my @files; my $parser = new XML::DOM::Parser; my $doc = $parser->parsefile($file) || die; my $prevlocs = $doc->getElementsByTagName('prevlocs') || die; my $prevloc = $prevlocs->item(0) || die; my $locs = $prevloc->getElementsByTagName('loc') || die; my $loc = $locs->item(0) || die; my $href = $loc->getAttributeNode('href') || die; print $href->getValue(). "\n" || die;
Received on Friday, 30 July 2004 04:51:26 UTC