I need to know the way. I have got parsing down some nodes. But I was unable to get the child node perfectly. If you have code please send it. It will be very useful for me. (0 Replies)
I am very new to XML. Really I have an excel file that I am trying to read w/ Perl on a Linux machine. I don't have a mod for reading excel files so I have to convert the excel file to xml to be able to read it. I can read the file and everything is ok except...the Number style is being dropped... (0 Replies)
In the case that there are two cells under one row, I can only read the first cell. If anyone thinks they know how to deal with this please let me know.
XML code:
<Row>
<Cell><Data ss:Type="String">Loved</Data></Cell>
<Cell ss:Index="3"><Data ss:Type="Number">3.0</Data></Cell>
... (1 Reply)
Hi there,
I have need create and read (Handle) XML in perl, a lib with oop support. are you can present suitable library for this?
Thanks in advance. (1 Reply)
Hi there,
I'm newby in perl and XML. I can read and parse Xml with XML-Node upper XML::Parser, but how can I create XML tags and pack my individual data in it then send through socket. PLZ lead me :)
Thanks in Advance. (1 Reply)
Hi there,
I'm newby in perl and XML. I can read and parse Xml with XML-Node upper XML::Parser, but how can I create XML tags and pack my individual data in it then send through socket. PLZ lead me :)
Meanwhile what is your opinion about XML Writer library?
Thanks in Advance. (2 Replies)
Hi,
I have 2 questions:
a) Does getElementsByTagName in xml takes more time?
b) If it takes more time what are the other alternatives used to get the tag names?
For example:
<Student>
<Studname>aaa</Studname>
<Studno>123</Studno>
</Student>
This is just a sample data. The file... (2 Replies)
Hi,
I have an XML file with around 1 billion rows in it and i am trying to find the number of times a particular tag occurs in it. The solution i am using works but takes a lot of time (~1 hr) .Please help me with an efficient way to do this.
Lets say the input file is
<Root>
... (13 Replies)
Hi,
Am pretty new for perl scripting and confused how to use XML Parser..
I just want to know how to use perl and XML parser..
The scenario is when i execute a command, it will generate a XML file..
From that XML file generated i need to grep for specific term that has HTML TAG say... (2 Replies)
Hi Everyone,
I'm new here and I was checking this old post:
/shell-programming-and-scripting/180669-splitting-file-into-several-smaller-files-using-perl.html
(cannot paste link because of lack of points)
I need to do something like this but understand very little of perl.
I also check... (4 Replies)
Discussion started by: mcosta
4 Replies
LEARN ABOUT DEBIAN
xml::writer::string
String(3pm) User Contributed Perl Documentation String(3pm)NAME
XML::Writer::String - Capture output from XML::Writer.
SYNOPSIS
use XML::Writer;
use XML::Writer::String;
my $s = XML::Writer::String->new();
my $writer = new XML::Writer( OUTPUT => $s );
$writer->xmlDecl();
$writer->startTag('root');
$writer->endTag();
$writer->end();
print $s->value();
DESCRIPTION
This module implements a bare-bones class specifically for the purpose of capturing data from the XML::Writer module. XML::Writer expects
an IO::Handle object and writes XML data to the specified object (or STDOUT) via it's print() method. This module simulates such an object
for the specific purpose of providing the required print() method.
It is recommended that $writer->end() is called prior to calling $s->value() to check for well-formedness.
METHODS
XML::Writer::String provides three methods, "new()", "print()" and "value()":
"$s = XML::Writer::String-"new([list]);>
new() returns a new String handle.
"$count = $s-"print([list]);>
print() appends concatenated list data and returns number of items in list.
"$val = $s-"value([list]);>
value() returns the current content of the object as a scalar. It can also be used to initialize/overwrite the current content with
concatenated list data.
NOTES
This module is designed for the specific purpose of capturing the output of XML::Writer objects, as described in this document. It does
not inherit form IO::Handle. For an alternative solution look at IO::Scalar, IO::Lines, IO::String or Tie::Handle::Scalar.
AUTHOR
Simon Oliver <simon.oliver@umist.ac.uk>
COPYRIGHT
Copyright (C) 2002 Simon Oliver
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
SEE ALSO
XML::Writer, IO::Handle, IO::Scalar
perl v5.14.2 2002-03-06 String(3pm)