Perl Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesPerl Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old April 30th, 2001, 06:27 PM
getyourbiglobster getyourbiglobster is offline
Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2001
Posts: 17 getyourbiglobster User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
hello-

i am hosted with the free www.freedom2surf.com and all i want is a small form that sends the results to my email.

i have a cgi script that will do what i want, but do not know what to do next. i read on f2's site that the script can be uploaded to the www. folder, as well as cgi-bin.

anybody done this with f2s before?

Reply With Quote
  #2  
Old May 2nd, 2001, 03:52 PM
pieux pieux is offline
Seņor Member
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Aug 2000
Posts: 1,156 pieux User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 17 m 59 sec
Reputation Power: 10
You can simplify what you want to do by making the action of your form mailto:<address>, where <address> is the address to which you want to send the information.
__________________
Michael

Reply With Quote
  #3  
Old May 2nd, 2001, 06:20 PM
cbreits23 cbreits23 is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2001
Posts: 20 cbreits23 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via AIM to cbreits23
yes, but that would give out the email address of the person that is sending the email (can be a problem when privacy is an issue).

To install that script that you have, first make sure that all variables are correct. For example, make sure your sendmail is reflected in the sendmail variable in the script. Then, upload your script to the www directory (or any directory, f2s does not care where it is put). Once there, chmod the file to 755. Then, all you have to do, is create a form that sends the desired information to the script. If you would like more help, check out this link: http://www.users.f2s.com/faq/formmail.php3 or email me at cbreits23@home.com and I will set one up for you.

Reply With Quote
  #4  
Old May 2nd, 2001, 07:07 PM
getyourbiglobster getyourbiglobster is offline
Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2001
Posts: 17 getyourbiglobster User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
cbreits23--
thanks for the help! i was able to get the script and form to work. however, now i am having problems configuring it to send to multiple recipients.

thanks again for your help

Reply With Quote
  #5  
Old May 2nd, 2001, 07:21 PM
cbreits23 cbreits23 is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2001
Posts: 20 cbreits23 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via AIM to cbreits23
What kind of problems are you having?

Reply With Quote
  #6  
Old May 2nd, 2001, 09:22 PM
getyourbiglobster getyourbiglobster is offline
Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2001
Posts: 17 getyourbiglobster User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
well, just having one recipient is fine, but when i try to use two....

<input type=hidden name="recipient"
value="myemail@hotmail.com">

<input type=hidden name="recipient"
value="anotheremail@hotmail.com">

no email is sent to either address.

i've also tried:

<input type=hidden name="recipient"
value="myemail@hotmail.com , anotheremail@hotmail.com">

once again, 1 recipient is fine:

<input type=hidden name="recipient"
value="myemail@hotmail.com">

i'm probably missing something very small.
...like in the perl script itself. i think i will check there right now!

Reply With Quote
  #7  
Old May 2nd, 2001, 09:55 PM
cbreits23 cbreits23 is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2001
Posts: 20 cbreits23 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via AIM to cbreits23
Well, why don't you try this: Put all of your recipients in a file, like this:

$name1|$name2|$name3|etc...

Then, in your script, open that file, read it, split it by |. Then store them into an array called @names.

then, use the following piece of code to send your emails...

$length = @names;
for($i = 0;$i<$length;<++$i)
{
open(MAIL, "| $mailprogram -t");
print MAIL "To: @names[$i]\n";
print MAIL "From: $myaddress\n";
print MAIL "Subject: my subject\n";
print MAIL "whatever you want to have in your email...\n";
close(MAIL);
}

That piece of code should find the number of names (stored in $length), and then loop through all of the names in the array, sending an email to each of them.

Have any questions? Feel free to ask (don't know if I explained it well enough or not).

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPerl Programming > www.f2s.com email form


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 2 hosted by Hostway
Stay green...Green IT