Johannes,
I use xml files for configuration files at work. If you like I can share
some of the code that I use. Let me know
Kristofer
----Original Message Follows----
From: drieux <[EMAIL PROTECTED]>
To: Theuerkorn Johannes <[EMAIL PROTECTED]>
CC: cgi cgi-list <[EMAIL PROTECTED]>
Subject: Re: parsing xml files for variables
Date: Tue, 4 Jun 2002 06:25:00 -0700
On Tuesday, June 4, 2002, at 05:12 , Theuerkorn Johannes wrote:
>
[..]
>I try like that:
>
>snip ++++++++++++++++++++++++++++++++++++++++++++++++++++
>#looking for Trigger <testsystem>
>
>if (/<testsystem>\s/ .. /<\/testsystem>\s/)
> {
> if ( /^(.*)\s+/) {
> $testsystem = $1;
> chomp ($testsystem);
> }
> print "Testsystem: $testsystem";
> }
>snip ++++++++++++++++++++++++++++++++++++++
>The XML piece looks like this:
http://search.cpan.org/search?mode=module&query=XML
I have worked with the expat stuff - and it would
be my first choice....
The problem you would be running into with your basic
parser approach is that you need to do multi-line
parsing of the file - hence would want something
similar to the form of
http://www.wetware.com/drieux/pbl/RegEx/paraHablarRegular.txt
where you need to keep reading in lines till your pattern matches.
ciao
drieux
---
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
_________________________________________________________________
MSN Photos is the easiest way to share and print your photos:
http://photos.msn.com/support/worldwide.aspx
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]