Req #6161 [NEW]: Misleading Example in Mail documentation

From: Date: Mon, 05 Dec 2005 19:05:08 +0000
Subject: Req #6161 [NEW]: Misleading Example in Mail documentation
Groups: php.pear.doc 
Request: Send a blank email to pear-doc+get-7272@lists.php.net to get a copy of this message
From: ted at qtis dot co dot nz Operating system: All PHP version: Irrelevant Package: Documentation Bug Type: Feature/Change Request Bug description: Misleading Example in Mail documentation Description: ------------ This is not urgent but it should save lots of time for people using Mail for the first time. The example stated that you can set up the $recipients array as $recipients = ('To' => 'someone@abc.com', 'Bcc' => 'another@def.com); While this is technically correct it it misleading when you try to add multiple recipients e.g. if you want to have two 'To' recipients you might think from the example that you should write $recipients['To'][] = 'to1@ghi.com'; $recipients['To'][] = 'to2@xyz.com'; But this does not work becuase Mail implodes the $recipients array and does not interpret the 'To', 'Cc', or 'Bcc' keys in the array. It would probably me clearer just to use an example like $recipients[] = 'someone@abc.com'; $recipients[] = 'another@def.com'; Test script: --------------- N/A Expected result: ---------------- N/A Actual result: -------------- N/A -- Edit bug report at http://pear.php.net/bugs/bug.php?id=6161&edit=1 --

« previous php.pear.doc (#7272) next »