Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Node Parser too slow?

by gjb (Vicar)
on Nov 04, 2002 at 19:28 UTC ( [id://210255]=note: print w/replies, xml ) Need Help??


in reply to Node Parser too slow?

This doesn't answer your question directly, but I think it is relevant nevertheless.

Actually, this is a job for XSLT, the XML transformation language. The idea is that one describes a transformation of XML into "something else" which can be either XML, HTML, plain text, basically whatever you like.

If the XSLT modules on CPAN are worth their salt, they should be quite efficient, so maybe this is an occasion not to reinvent the wheel ;-)

XSLT is a W3C standard since a couple of years now, so the technology is quite mature.

Hope this helps, -gjb-

Replies are listed 'Best First'.
Re: Re: Node Parser too slow?
by grantm (Parson) on Nov 06, 2002 at 07:29 UTC

    My XSLT experience is fairly light so I'm keen to find out about real world applications. In the original poster's code he would encounter an element like this:

    <child id="2">435</child>

    At this point his code would then (recursively) parse down into the file called '435.xml'. I realise recursive processing is no problem for XSLT, but how would you load in another file and process it?

      Oops, I should have read the code more carefully. I thought it was just an XML file that was converted to HTML without recursion.

      Recursion complicates matters to the point that you have to do major hacking in order to get this to work with XSLT if it is possible at all.

      Thanks for pointing this out, -gjb-

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://210255]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (3)
As of 2024-04-24 21:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found