Hi all, I'm trying to produce some meaningful xml with TaglibHelper.
Inside a loop I'm doing something like;
push @taglib_options,{id=>$taglib_poll_options- >[$i]{"id"},description=>$taglib_poll_options- >[$i]{"description"},count=>$taglib_poll_options->[$i]{"count"};
Then later in my code i use the compiled array of hashes as an element within a larger array of hashes;
push @taglib_polls,{options=>[EMAIL PROTECTED],status=>$taglib_poll_status,id =>$taglib_poll_options->[$i]{"poll_id"},title=>$taglib_poll_options- >[$i]{"title"},description=>$taglib_poll_options->[$i]{"question"}};
I then return the derived xml; return {polls=>[EMAIL PROTECTED],debug=>$debug}
All works fine and i get, (slightly tainted, just debugging);
<options>
<HASH(0x620360)>
<count>3</count><id>53</id><description>What's an iPod</description>
</HASH(0x620360)>
<HASH(0x7d38f0)>
<count>3</count><id>51</id><description>Maybe</description>
</HASH(0x7d38f0)>
</options>
What i'd like is to replace 'HASH(0x620360)' with something meaningful, but despite my best efforts i can't get it to play.
I've tried modifying the original push to so as not to use an anonymous hash but so far i've had no luck;
my %options = (id=>$taglib_poll_options- >[$i]{"id"},description=>$taglib_poll_options- >[$i]{"description"},count=>$taglib_poll_options->[$i]{"count"});
push @taglib_options,\%options;
I know this is probably me just being stupid an a simple change of how i pass my references will solve the problem, but any clues greatly appreciated.
Mark.
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]