I'm going to use your code with XSLT. I asked you if there's an instruction to search all the xml files contained in that folder at once. How XSLT 'understands' that the following instruction will be executed for all these files in a specific folder:
<xsl:template match="Texte">...
Ok, so you think that is better to process directly the folder that contains the xml files. Is there a XSLT instruction that allows to search and process all the contents of that folder? Thanks
This is a sample of the txt file, where you can see only two of the xml documents. Normally this list continues with a third, fourth etc...(over 6.000 xml documents in total).
Thank you
Hello,
I have a folder containing a large number of .xml files. Alternatively, i have also a .txt file that contains all these .xml like text. These documents come from newspaper's articles in xml format. There's is a sample:
<?xml version="1.0" encoding="UTF-8"?>
<Document...
Thanks, that's it! Now it works, but only with the code to export one only txt file with the content of all xml's:
use XML::Twig;
my $xml_dir = 'C:\xmlperl';
my $cnt = 0;
my $out;
opendir(DIR,$xml_dir) || die;
my @TranscriptsList = grep(/xml$/, readdir(DIR));
closedir(DIR);
foreach...
Hi,
i've change $xml_dir to $file but i gives always the same error...
use XML::Twig;
my $file = 'C:\xmlperl';
my $cnt = 0;
my $out;
opendir(DIR,$file) || die;
my @TranscriptsList = grep(/xml$/, readdir(DIR));
closedir(DIR);
foreach $file (@TranscriptsList) {
my $twig= new...
Hello,
thank you for the help. Now i tested my code like this:
use XML::Twig;
my $xml_dir = 'C:\xmlperl';
my $cnt = 0;
my $out;
opendir(DIR,$xml_dir) || die;
my @TranscriptsList = grep(/xml$/, readdir(DIR));
closedir(DIR);
foreach $file (@TranscriptsList) {
my $twig= new...
Hello,
I have a large number of xml files in a folder. I want to read and extract the content of each xml file to a new.txt. I'm only interested in the content having the tag <Texte>, and i want to create a .txt file (a texte file for each of my xml's). I use the perl modules xml twig and xml...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.