08-04-2008
Quote:
Originally Posted by
pvr_satya
how can i find data if multiple tags present ( i mean dynamically)
Did you try my solution?
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I am having xml document as below.
<transactionid>
00
</transactionid>
<tracknumber>
0
</tracknumber>
<key>
N/A
</key>
But the data contains leading and trailing spaces between the tags. Please let me know how can i remove these leading and trailing spaces between the tags.... (2 Replies)
Discussion started by: jhmr7
2 Replies
2. Shell Programming and Scripting
Is there a way to modify Non Null data between <host> and </host> tags to a new value ?- may be using sed/awk?
I tried this sed 's|.*<host>\(?*\)</host>.*|\<host>xxx</host>|' but it is updating the host which has null value - want opposite of this - Thanks in advance for you help!!
For... (2 Replies)
Discussion started by: harry_todd
2 Replies
3. Shell Programming and Scripting
<?xml version="1.0" encoding="iso-8859-1" ?>
<TABLE>
<TEST>
<ID> 123 </ID>
<name> abc </name>
</TEST>
<TEST>
<ID> 123 </ID>
<name> abc2 </name>
</TEST>
</TABLE>
<TABLE>
<TEST>
<ID> 456 </ID>
<name> def </name>
</TEST>
<TEST>
... (8 Replies)
Discussion started by: eskay
8 Replies
4. Shell Programming and Scripting
Hi All,
I'm trying to extract data from an xml file but without the codes. I've achieved it but i was wondering if there's a better way to do this.
sample data:
$ cat xmlfile
<code>
<to>tove</to>
<from>jani</from>
<heading>reminder</heading>
<body>dont forget me</body>
</code>
... (4 Replies)
Discussion started by: Irishboy24
4 Replies
5. Shell Programming and Scripting
Hi,
I am new to shell scripting. I need to extract data between repeating tags from an xml file and store the data in an array to process it further.
<ns1:root xmlns:ns1="http://example.com/config">
<ns1:interface>in1</ns1:interface>
<ns1:operation attribute1="true" attribute2="abd"... (2 Replies)
Discussion started by: sailendra
2 Replies
6. Shell Programming and Scripting
I've got two different files and want to compare them.
File 1 :
<response ticketId="944" type="getQueryResults"><status>COMPLETE</status><description>Query results fetched successfully</description><recordSet totalCount="1" type="sms_records"><record id="38,557"><columns><column><name>orge... (2 Replies)
Discussion started by: Shaishav Shah
2 Replies
7. Shell Programming and Scripting
Hi folks
I have a script I wrote that basically parses a bunch of config and xml files works out were to add in the new content then spits out the data into a new file.
It all works - apart from the xml and config file format in the new file
with XML files the original XML (that ends up in... (2 Replies)
Discussion started by: dfinch
2 Replies
8. UNIX for Advanced & Expert Users
Hi unix Gurus,
I am really new to Unix Scripting. Please help me to create a shell script which reads the xml file and from that i need to fetch a particular information.
For example
<SOURCE BUSINESSNAME ="" DATABASETYPE ="Teradata" DBDNAME ="DWPROD3" DESCRIPTION ="" NAME... (2 Replies)
Discussion started by: SmilePlease
2 Replies
9. Shell Programming and Scripting
Hi All,
I have a requirement to change the data in xml file to required format.
Below is the scenario.
Please find the attached Xml file which contains data that I need to convert..
<ReleaseIndicatorList><ReleaseIndicator>Alternative... (0 Replies)
Discussion started by: Prathyu
0 Replies
10. UNIX for Dummies Questions & Answers
Hi,
I need help in extracting only the phone numbers between the continuous non empty xml tags in unix. I searched through a lot of forum but i did not get exact result for my query. Please help
Given below is the sample pipe delimited file. I have a lot of tags before and after... (6 Replies)
Discussion started by: zen01234
6 Replies
LEARN ABOUT PHP
tidy_get_config
TIDY_GET_CONFIG(3) 1 TIDY_GET_CONFIG(3)
tidy::getConfig - Get current Tidy configuration
Object oriented style
SYNOPSIS
array tidy::getConfig (void )
DESCRIPTION
Procedural style
array tidy_get_config (tidy $object)
Gets the list of the configuration options in use by the given tidy $object.
PARAMETERS
o $object
- The Tidy object.
RETURN VALUES
Returns an array of configuration options.
For an explanation about each option, visit http://tidy.sourceforge.net/docs/quickref.html.
EXAMPLES
Example #1
tidy_get_config(3) example
<?php
$html = '<p>test</p>';
$config = array('indent' => TRUE,
'output-xhtml' => TRUE,
'wrap' => 200);
$tidy = tidy_parse_string($html, $config);
print_r($tidy->getConfig());
?>
The above example will output:
Array
(
[indent-spaces] => 2
[wrap] => 200
[tab-size] => 8
[char-encoding] => 1
[input-encoding] => 3
[output-encoding] => 1
[newline] => 1
[doctype-mode] => 1
[doctype] =>
[repeated-attributes] => 1
[alt-text] =>
[slide-style] =>
[error-file] =>
[output-file] =>
[write-back] =>
[markup] => 1
[show-warnings] => 1
[quiet] =>
[indent] => 1
[hide-endtags] =>
[input-xml] =>
[output-xml] => 1
[output-xhtml] => 1
[output-html] =>
[add-xml-decl] =>
[uppercase-tags] =>
[uppercase-attributes] =>
[bare] =>
[clean] =>
[logical-emphasis] =>
[drop-proprietary-attributes] =>
[drop-font-tags] =>
[drop-empty-paras] => 1
[fix-bad-comments] => 1
[break-before-br] =>
[split] =>
[numeric-entities] =>
[quote-marks] =>
[quote-nbsp] => 1
[quote-ampersand] => 1
[wrap-attributes] =>
[wrap-script-literals] =>
[wrap-sections] => 1
[wrap-asp] => 1
[wrap-jste] => 1
[wrap-php] => 1
[fix-backslash] => 1
[indent-attributes] =>
[assume-xml-procins] =>
[add-xml-space] =>
[enclose-text] =>
[enclose-block-text] =>
[keep-time] =>
[word-2000] =>
[tidy-mark] =>
[gnu-emacs] =>
[gnu-emacs-file] =>
[literal-attributes] =>
[show-body-only] =>
[fix-uri] => 1
[lower-literals] => 1
[hide-comments] =>
[indent-cdata] =>
[force-output] => 1
[show-errors] => 6
[ascii-chars] => 1
[join-classes] =>
[join-styles] => 1
[escape-cdata] =>
[language] =>
[ncr] => 1
[output-bom] => 2
[replace-color] =>
[css-prefix] =>
[new-inline-tags] =>
[new-blocklevel-tags] =>
[new-empty-tags] =>
[new-pre-tags] =>
[accessibility-check] => 0
[vertical-space] =>
[punctuation-wrap] =>
[merge-divs] => 1
)
SEE ALSO
tidy_reset_config(3), tidy_save_config(3).
PHP Documentation Group TIDY_GET_CONFIG(3)