Softpedia
 


LINUX CATEGORIES:



GLOBAL PAGES >>
NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
WEEK'S BEST
  • Linux Kernel 3.9.3 / 3....
  • LibreOffice 3.6.6 / 4.0.3
  • MPlayer 1.1.1
  • systemd 204
  • Arch Linux 2013.05.01
  • Blender 2.67a
  • KDE Software Compilatio...
  • CrunchBang Linux Stable...
  • Elementary OS 0.1 / 0.2...
  • SystemRescueCd 3.6.0
  • Home > Linux > Programming > Libraries

    XML::Mini::Element 1.2.8

    Download button

    No screenshots available
    Downloads: 267  View global page NEW!  Tell us about an update
    User Rating:
    Rated by:
    NOT RATED
    0 user(s)
    Developer:

    License / Price:

    Last Updated:

    Category:
    Patrick Deegan | More programs
    Perl Artistic License / FREE
    March 9th, 2007, 02:05 GMT
    ROOT / Programming / Libraries

     Read user reviews (0)  Refer to a friend  Subscribe

    XML::Mini::Element description

    XML::Mini::Element is a Perl implementation of the XML::Mini Element API.

    XML::Mini::Element is a Perl implementation of the XML::Mini Element API.

    SYNOPSIS

    use XML::Mini::Document;

    my $xmlDoc = XML::Mini::Document->new();

    # Fetch the ROOT element for the document
    # (an instance of XML::Mini::Element)
    my $xmlElement = $xmlDoc->getRoot();

    # Create an tag
    my $xmlHeader = $xmlElement->header('xml');

    # add the version to get
    $xmlHeader->attribute('version', '1.0');

    # Create a sub element
    my $newChild = $xmlElement->createChild('mychild');

    $newChild->text('hello mommy');


    # Create an orphan element

    my $orphan = $xmlDoc->createElement('annie');

    $orphan->attribute('hair', '#ff0000');
    $orphan->text('tomorrow, tomorrow');

    # Adopt the orphan
    $newChild->appendChild($orphan);


    # ...
    # add a child element to the front of the list
    $xmlElement->prependChild($otherElement);

    print $xmlDoc->toString();

    The code above would output:
    < ?xml version="1.0" ? > < mychild > hello mommy < annie hair="#ff0000" > tomorrow, tomorrow < /annie > < /mychild >

    Product's homepage

    Requirements:

    · Perl

      


    TAGS:

    Element API | XML::Mini Element | Perl module | XML::Mini::Element | XML::Mini | Element

    Go to top

    WindowsGamesDriversMacLinuxScriptsMobileHandheldNews

    SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   UPDATE YOUR SOFTWARE   |   ROMANIAN FORUM