Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

I am trying to output the contents of a simple xml file to my left hand menu, but cannot figure out how to get the elements to display. my xml file is like this..
<mlx> <link tab="Support" view="Search" title="Search"> <description>Search our Help Articles</description> <header>0</header> </link> <link tab="support" view="someotherview" title="next view"> <description>example description</description> <header>0</header> </link> </mlx> i was thinking I could do like this but its not working. my $xml = xmlFileData("Content", "mlx.xml", "mLeftIndex()"); $xml =~ s/(<\/leftIndex>)/$logoutLink$1/s; $xml="<\/leftIndex>"; $str .= $xml; last SWITCH; } }
xmlfiledata is a subroutine that sets up xpath to the file in question it takes as arguments $path $file and $caller

Replies are listed 'Best First'.
Re: output xml file
by gman (Friar) on Sep 14, 2009 at 15:49 UTC

    Anonymous,

    Could you post your code? Hard to guess what you are asking here.