General Programming Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsProgrammingGeneral Programming Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old December 16th, 2003, 12:07 AM
One22One One22One is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Posts: 1 One22One User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
How can i Send For More than one mail

Hi Mates ..
I want to ask about a Sending Mails for Defined By Visitor using
RadiaBox ..

but how can know if he put Right at the radiobox or not ,
to know if he want to send mail for who ..

i Hope you understood me ..

Reply With Quote
  #2  
Old December 16th, 2003, 07:32 AM
dhouston's Avatar
dhouston dhouston is offline
Contributing User
Dev Articles Beginner (1000 - 1499 posts)
 
Join Date: May 2003
Location: Tennessee
Posts: 1,355 dhouston User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 7
Send a message via ICQ to dhouston
I think you're saying the following:

1. You want a set of radio buttons corresponding to different email addresses.
2. When somebody fills out the form, they select a radio button.
3. The email should go to the address corresponding to the radio button clicked.

If so, then you need to check for $_POST["radio_name"] and use that value to determine which email address to send to. If I'm mistaken, you'll need to clarify your question.

Reply With Quote
  #3  
Old December 16th, 2003, 07:35 AM
dhouston's Avatar
dhouston dhouston is offline
Contributing User
Dev Articles Beginner (1000 - 1499 posts)
 
Join Date: May 2003
Location: Tennessee
Posts: 1,355 dhouston User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 7
Send a message via ICQ to dhouston
I just reread the subject line. If you want to send to more than one email, you need to use checkboxes rather than radio buttons. When you name your checkbox, name it with brackets appended to the end:

Code:
<input type="checkbox" name="email[]" value="blah@blah.com"><br>

<input type="checkbox" name="email[]" value="blah2@blah.com">


Then when you're processing the form submittal, treat $_POST["email"] as an array:

PHP Code:
foreach($_POST["email"] as $email){
    
mail($email,$subject,$message,$headers);


Reply With Quote
  #4  
Old December 16th, 2003, 08:16 AM
Ara-Tech Ara-Tech is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Posts: 5 Ara-Tech User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Thanks Mr dhouston for Helping ..
That's what i want to know Exactly

i was Thinking :-
i can do that
PHP Code:
if(isset($radio_name)) 
{
mail($email,$subject,$message,From:Ara-tech@ara-tech.com)


I can do that .. i did not Try it but i think it works .
Best Regards

Reply With Quote
  #5  
Old December 16th, 2003, 11:56 AM
nicat23's Avatar
nicat23 nicat23 is offline
Addicted to Chaos..
Dev Articles Novice (500 - 999 posts)
 
Join Date: Jan 2003
Location: Ft. Worth, TX
Posts: 653 nicat23 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 47 m 52 sec
Reputation Power: 0
Send a message via AIM to nicat23 Send a message via Yahoo to nicat23
Ara, the easiest way would probably be to assign it to an array like dhouston recomended, and do the foreach or a similar statement to step through each of the emails which you want to send the email to, I dont think that the
PHP Code:
if(isset($radio_name))  

mail($email,$subject,$message,From:Ara-tech@ara-tech.com

would work in your situation due to the fact that you want to send to more than one email address.. and that would only send to the first (or possibly last, depending..) email address in your list

Reply With Quote
  #6  
Old December 16th, 2003, 12:35 PM
Ara-Tech Ara-Tech is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Posts: 5 Ara-Tech User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Thanks A lot
i will use dhousten Code ..
Best Regards

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingGeneral Programming Help > How can i Send For More than one mail


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway