Advertisement

05.26.2005 at 07:39AM PDT, ID: 21437719
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

7.8

Problem in bulk mail sending

Asked by ashokguru in CGI Scripting

Tags: , , , ,

I have problem in sending bulk mails using perl. email id's are being read from the database which is MySQL.

I'm able to read the email id's from the database and I'm getting the confirmation message stating that the mail has been sent, but actually the mail is not going. But if I send email to only one email Id the mail is going. Please let me know what might be the problem.

thanks in advance
Ashok

Here is the code
----------------------

#! /usr/bin/perl

print "Content-type: text/html \n\n";

require "../../quickpro/config.pl";
require "../../quickpro/sconfig.pl";
require "globals.pl";
require "variables.pl";

use CGI::Carp qw/fatalsToBrowser/;
use CGI qw (:standard);

$form=new CGI;
@variables=$form->param;

foreach $variables(@variables){${$variables}=$form->param($variables);}

&connect_sql;
$SQL="SELECT * from recipientstemp";
&my_sql;
$i=1;
while($column=$sth->fetchrow_hashref)
{
        $id=$column->{'ID'};
        $firstname=$column->{'firstname'};
        $lastname=$column->{'lastname'};
        $email=$column->{'email'};
        $phone=$column->{'phone'};
        $url=$column->{'url'};
        $company=$column->{'company'};
        $ipaddr=$column->{'ipaddress'};
        $confirmlink="$DomainURL/cgi-bin/quickpro/success.cgi?id=$id";
        &personalize;
       
        #print "$id,$firstname,$email,$ipaddr";
       
        $email=~s/@/\@/g;
        $from=~s/@/\@/g;
        if($i==1)
        {
          $temp=$email;
          $i++;
        }
        else
        {
        $temp=$temp.",".$email;  
        print $temp;
        }
}

   unless(open (MAIL, "|/usr/sbin/sendmail -t"))
         {
            print "error.\n";
         }
        else
        {
        #open (MAIL, "|$sendmail -t") || die "I can't open sendmail\n";
        print MAIL "To: $firstname <$temp>\n";
        print MAIL "From:$from\n";
        print MAIL "Subject:$subject\n";
        print MAIL "Mime-Version:1.0\n";
        print MAIL "Content-Type:text/plain\; charset=\"US-ASCII\"\n";
        print MAIL "Content-Transfer-Encoding: 7bit\n";
        print MAIL $message;
        close(MAIL);
        print "Mail sent";
        }        
$sth->finish;
$dbh->disconnect;
#print "<a href=$DomainURL/cgi-bin/quickpaypro/success.cgi?id=$id>";

print qq|
<html>
<body>
<table border="0" cellpadding="0" cellspacing="0" width="100%" bgcolor="$darkcolor"  background="$DomainURL/images/$mybackground">
                  <tr>
                        <td><img height="60" width="360" src="$DomainURL/images/$mylogo"></td>
                  </tr>
</table>
<center>
<br><br>
<b>Confirmation mail has been sent</b>      
     
</body>
</html>      
|;      
             Start Free Trial
[+][-]05.26.2005 at 08:11AM PDT, ID: 14086710

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zone: CGI Scripting
Tags: quickpaypro, bulk, email, mail, sending
Sign Up Now!
Solution Provided By: Peewee
Participating Experts: 2
Solution Grade: A
 
 
[+][-]05.26.2005 at 02:39PM PDT, ID: 14090259

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 7-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]06.25.2005 at 08:30AM PDT, ID: 14300084

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]06.28.2005 at 05:13AM PDT, ID: 14317298

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.16.2005 at 06:33AM PDT, ID: 14457505

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]07.16.2005 at 12:25PM PDT, ID: 14459094

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.17.2005 at 01:56AM PDT, ID: 14460814

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.20.2005 at 09:55AM PDT, ID: 14486706

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32