GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
XML::Normalize::LibXML(3) User Contributed Perl Documentation XML::Normalize::LibXML(3)

XML::Normalize::LibXML - simple whitespace striping functions

use XML::Normalize::LibXML qw(trim xml_normalize xml_strip_whitespace);

$greeting=trim(" hallo world "); # returns "hallo world" xml_normalize($dom->getDocumentElement()); xml_strip_whitespace($dom->getDocumentElement());

This module provides simple whitespace striping and text-node normalizing functions.

Returns the string with any whitespace occuring at its beginning or end removed.

Puts all Text nodes in the full depth of the sub-tree underneath this Element into a normal form where only markup (e.g., tags, comments, processing instructions, CDATA sections, and entity references) separates Text nodes, i.e., there are no adjacent Text nodes. This can be used to ensure that the DOM view of a document is the same as if it were saved and re-loaded, and is useful when operations (such as XPointer lookups) that depend on a particular document tree structure are to be used.

Normalizes the subtree and trims whitespace from all Text nodes within the subtree. If the optional argument $include_attributes is defined and non-zero, this function trims whitespace also from all Attribute nodes.

Removes leading and trailing whitespace from a given element.

Petr Pajas, pajas@matfyz.cz

Copyright 2002-2003 Petr Pajas, All rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

XML::LibXML
2003-12-03 perl v5.32.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.