I'm trying to produce a simple XML document from the CGI parameters submitted in a form. This is basically what I'm doing:
my $xs = new XML::Simple(); my $elements = $cgi->Vars(); my $xml = $xs->XMLout( $elements, rootname => 'source' );
So $elements is a reference to a hash where the key is the CGI parameter and the value is the value associated with that parameter. The CGI parameters I don't want in the XML are prefixed with "-" which according to the XML::Simple docs should omit them from the XML.
The problem is the contents of $xml look like this: <source></source> ie no elements get written into the output. Can anyone offer some advice as to what I have missed?
Thanks.
In reply to XML from CGI parameters by ezekiel
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |