form goes to multiple email addresses

weikelbob
weikelbob used Ask the Experts™
on
How do I alter this line in my php form handler so that the email goes to more than one email address?:

if (!mail('lporter@level10marketing.com','From Level10 Website Dealer Advantage Page',$message)) die('Mail Failed!');

Thanks !
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Seperate the multiple address by a comma:

if (!mail('lporter@level10marketing.com, otheraddress@domain.com','From Level10 Website Dealer Advantage Page',$message)) die('Mail Failed!');
Vel EousResearch & Development Manager

Commented:
If your getting the main email address from a form, you may want to use the following:

// multiple recipients
$to  = $_POST['email_input'] . ', ';
$to .= 'other_email@yoursite.com';

Author

Commented:
Thanks both of you.

I got it.

Bob
Rowby Goren Makes an Impact on Screen and Online

Learn about longtime user Rowby Goren and his great contributions to the site. We explore his method for posing questions that are likely to yield a solution, and take a look at how his career transformed from a Hollywood writer to a website entrepreneur.

For the record, do you mind telling which solution worked for you, so that this question can be finished?

Author

Commented:
I apologize,

My internet has been down.

glcummins: your comment worked. I noted Tchuki's comment for later use. I guess the most appropriate point assignment would be to accept glcummins' post.

Thanks again.

Bob
Vel EousResearch & Development Manager

Commented:
/cry

:P

Glad its sorted  :)

Author

Commented:
Do you guys think that Tchuki should get half the points?

I have no problem splitting points if that is more appropriate. I too am an expert and I cherish every point I get.

Let me know,

Bob
Vel EousResearch & Development Manager

Commented:
lol, I dont think they should be split.  If you went with glcummins example then he/she deserves the points for it.

Author

Commented:
OK I just wanted to make sure :)

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial