for ( $thread ) { my %data2; $data2{author} = $thread->author; $data2{date} = $thread->date; $data2{content} = $thread->content; push @d_body, \%data2; } #### push @d_body, {}; $d_body[-1]->{$_} = $thread->$_ for ("author", "date", "content"); #### my $d_body; $d_body->{$_} = $thread->$_ for ("author", "date", "content"); #### body=> [$d_body],
## push @d_body, {}; $d_body[-1]->{$_} = $thread->$_ for ("author", "date", "content"); ##
## my $d_body; $d_body->{$_} = $thread->$_ for ("author", "date", "content"); ##
## body=> [$d_body],