?
Solved

Send registration form to multiple address'

Posted on 2011-09-20
2
Medium Priority
?
296 Views
Last Modified: 2012-05-12
I have set up a registration form which works fine. Currently though it only sends a confirmation to the user, I would also like an email sent to admin registration@domain.com.

Any ideas how to do this?

I have attached the code which applies to sending the user email...

// Send the email:
				$body = "Thank you for registering at <whatever site>. To activate your account, please click on this link:\n\n";
				$body .= BASE_URL . 'activate.php?x=' . urlencode($e) . "&y=$a";
				mail($trimmed['email'], 'Registration Confirmation', $body, 'From: registration@anjoman.co.uk');

Open in new window

0
Comment
Question by:BrighteyesDesign
2 Comments
 
LVL 9

Accepted Solution

by:
ghodder earned 2000 total points
ID: 36570297
You just need to concatenate your second email address into the first parameter, prefixed with a comma like so

 mail($trimmed['email'] . ', registration@domain.com', 'Registration Confirmation', $body, 'From: registration@anjoman.co.uk');

Open in new window

0
 

Author Closing Comment

by:BrighteyesDesign
ID: 36572152
Perfect, thanks
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses four methods for overlaying images in a container on a web page
The title says it all. Writing any type of PHP Application or API code that provides high throughput, while under a heavy load, seems to be an arcane art form (Black Magic). This article aims to provide some general guidelines for producing this typ…
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to count occurrences of each item in an array.
Suggested Courses
Course of the Month15 days, 12 hours left to enroll

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question