note 95133 modified in function.imap-body by danbrown

From: Date: Tue, 15 Dec 2009 03:26:48 +0000
Subject: note 95133 modified in function.imap-body by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-163979@lists.php.net to get a copy of this message
Simple example on how to read body message of the recent mail. <?php $imap = imap_open("{pop.example.com:995/pop3/ssl/novalidate-cert}", "username", "password"); if( $imap ) { //Check no.of.msgs $num = imap_num_msg($imap) //if there is a message in your inbox if( $num >0 ) { //read that mail recently arrived echo imap_qprint(imap_body($imap, $num)); } //close the stream imap_close($imap); } ?> --was-- Simple example on how to read body message of the recent mail. $imap = imap_open("{yourpopservername:995/pop3/ssl/novalidate-cert}", "username", "password"); if( $imap ) { //Check no.of.msgs $num = imap_num_msg($imap) //if there is a message in your inbox if( $num >0 ) { //read that mail recently arrived echo imap_qprint(imap_body($imap, $num)); } //close the stream imap_close($imap); } http://php.net/manual/en/function.imap-body.php

« previous php.notes (#163979) next »