Hi All,
I'm trying to extract the values for the 'src' and 'alt' tags within an xml file. In the files that I'm searching, the tags are always enclosed within an 'img' tag. Typically:
<img src="diwiz01.gif" width="576" height="254" alt="Out-of-process and In-process COM Objects"><bookmark... (3 Replies)
Greetings,
I am very new to the UNIX shell scripting and would like to learn. However, I am currently stuck on how to process the below sample of code from an XML file using UNIX comands:
<ATTRIBUTE NAME="Memory" VALUE="512MB"/>
<ATTRIBUTE NAME="CPU Speed" VALUE="3.0GHz"/>
<ATTRIBUTE... (5 Replies)
Hi All,
Please help me out in resolving this..
<secondTag enabled='true' processName='test1' pidFile='/tmp/test1.pid' />
From the above tag, I'm trying to retrieve the value of enabled and pidFile attributes by means of processName attribute.
Would be thankful in resolving this..... (5 Replies)
Hi All,
Find the following code:
<Universal>D38x82j1JJ
</Universal>
I want to retrieve the value of <Universal> tag as below:
Please help me. (3 Replies)
Hi All,
I'm stuck with adding multiple lines(irrespective of line number) to a file before a particular xml tag. Please help me.
<A>testing_Location</A>
<value>LA</value>
<zone>US</zone>
<B>Region</B>
<value>Russia</value>
<zone>Washington</zone>
<C>Country</C>... (0 Replies)
Hi Guys
Here is my Input :
<?xml version="1.0" encoding="UTF-8"?>
<xn:MeContext id="01736">
<xn:VsDataContainer id="01736">
<xn:attributes>
<xn:vsDataType>vsDataMeContext</xn:vsDataType>
... (12 Replies)
I want to basically do the below thing. Suppose there is a tag called object1. I want to display an output for all similar tag values under heading of Object 1 and the count of the xmls. Please help
File:
<xml><object1>house</object1><object2>child</object2>... (9 Replies)
Hi,
My requirement is something like this,
I have a xml file that contains some tags and nested tags,
<n:tag_name1>
<n:sub_tag1>val1</n:sub_tag1>
<n:sub_tag2>val2</n:sub_tag2>
</n:tag_name1>
<n:tag_name2>
<n:sub_tag1>value</n:sub_tag1>
... (6 Replies)
Hi Forum.
I have an XML file with the following requirement to move the <AdditionalAccountHolders> tag and its content right after the <accountHolderName> tag within the same file but I'm not sure how to accomplish this through a Unix script.
Any feedback will be greatly appreciated.
... (19 Replies)
I want to write a one line script that outputs the result of multiple xml tags from a XML file. For example I have a XML file which has below XML tags in the file:
<EMAIL>***</EMAIL>
<CUSTOMER_ID>****</CUSTOMER_ID>
<BRANDID>***</BRANDID>
Now I want to grep the values of all these specified... (1 Reply)
Discussion started by: shubh752
1 Replies
LEARN ABOUT REDHAT
xml::dumper
Dumper(3) User Contributed Perl Documentation Dumper(3)NAME
XML::Dumper - Perl module for dumping Perl objects from/to XML
SYNOPSIS
# Convert Perl code to XML
use XML::Dumper;
my $dump = new XML::Dumper;
$data = [
{
first => 'Jonathan',
last => 'Eisenzopf',
email => 'eisen@pobox.com'
},
{
first => 'Larry',
last => 'Wall',
email => 'larry@wall.org'
}
];
$xml = $dump->pl2xml($perl);
# Convert XML to Perl code
use XML::Dumper;
my $dump = new XML::Dumper;
# some XML
my $xml = <<XML;
<perldata>
<scalar>foo</scalar>
</perldata>
XML
# load Perl data structure from dumped XML
$data = $dump->xml2pl($Tree);
DESCRIPTION
XML::Dumper dumps Perl data to a structured XML format. XML::Dumper can also read XML data that was previously dumped by the module and
convert it back to Perl.
This is done via the following 2 methods: XML::Dumper::pl2xml XML::Dumper::xml2pl
AUTHOR
Jonathan Eisenzopf <eisen@pobox.com>
CREDITS
Chris Thorman <ct@ignitiondesign.com> L.M.Orchard <deus_x@pobox.com> DeWitt Clinton <dewitt@eziba.com>
SEE ALSO perl(1), XML::Parser(3).
perl v5.8.0 1999-06-20 Dumper(3)