generating attributes and content for an element
Manuel Souto Pico <[email protected]>
| Newsgroups | gmane.comp.lang.perl.xml |
|---|---|
| Message-ID | <[email protected]> |
Hi,
This is my first email to this list, so hello everyone! :)
I'm starting to learn XML with Perl (and I'm not an experienced Perl
programmer either), so I'd be thankful if you could be patient ;)
The doubt that I have is about generating both content* and attributes
for an element.
(*): content which is not other elements, that is.
By means of
my $data = {
e => ['element value'],
a => 'attribute value'*
*};
I can get this:
<root a="attribute value">
<e>element value</e>
</root>
However, what I'm after is something like
<root>
<e a="attribute value">element value</e>
</root>
I would be very grateful for any ideas.
Thank you!
Manuel
_______________________________________________
Perl-XML mailing list
[email protected]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs