llvidya Posted July 19, 2012 Share Posted July 19, 2012 Hai, pls help in d ownloading all attachments foreach($emails as $email_id){ //for($i=0) // Fetch the email's overview and show subject, from and date. $overview = imap_fetch_overview($stream,$email_id,0); $message = imap_fetchbody($stream,$email_id,2); $structure = imap_fetchstructure($stream,$email_id); //echo $name = $structure->parts[1]->value; ?> <div class="email_item clearfix <?=$overview[0]->seen?'read':'unread'?>" onClick=togglefun(<?php echo $email_id; ?>); id=<?php echo $email_id; ?> style="margin-top:30px;"> <? // add a different class for seperating read and unread e-mails ?> <input type="hidden" value="<?php echo $email_id; ?>" name="mailid"> <span class="subject" title="<?=decode_imap_text($overview[0]->subject)?>"><?=decode_imap_text($overview[0]->subject)?></span> <span class="from" title="<?=decode_imap_text($overview[0]->from)?>"><?=decode_imap_text($overview[0]->from)?></span> <span class="date"><?=$overview[0]->date?></span> </div> <div class="msgbody" style="display:none;" id=<?php echo 'msg'.$email_id; ?> > <?php echo $message; ?> <input type="button" value="Close" name="closeBtn" onClick="hidetoggle(<?php echo $email_id; ?>);"> <input type="hidden" value="<?php 'msg'.$email_id; ?>" name="mailid"> </div> <?php //echo $mailcount; // $roundmail = round($mailcount/10); ?> <? } Quote Link to comment Share on other sites More sharing options...
andrew_biggart Posted July 19, 2012 Share Posted July 19, 2012 Any reason why you have posted this topic twice? Please also put your code inside the code tags as it makes it easier for people to read. Thanks. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.