Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Automatic Mail to customers that didn't checkout


compuskill

Recommended Posts

Hi,

 

I am looking for a way to send automatic emails to customers that have created an account and who have put stuff into the shopping cart but haven't checked out. So basically, it is a script that asks possible customers if they have had any problems or questions. Does something like that already exist? With language support?

 

Thx guys,

compuskill

Link to comment
Share on other sites

Uhm... or can someone help me with the syntax for the mysql query? The database would have to be modified either way to mark which

 

customers have already received such a mail, for example in the table "customers_basket": Reminder sent? Y or N

 

It would have to work like this:

 

1) What is the email address of the customers that have stuff in their shopping cart whose reminer sent value is N

2) Send a mail to these customers

3) The shopping cart reminder has to be switched to Y.

 

For 1)

$strSQL="SELECT customers_email_address  FROM customers INNER JOIN customers_id ON customers.customers_id = customers_basket.customers_id 

WHERE customers_basekt.reminder="N"; 
		$Erg=mysql_query($strSQL);
		while ($Zeile=mysql_fetch_array($Erg))
		{
		echo "<option value=\"$Zeile[0]\">$Zeile[0]</option>";
		}

 

For 2)

<?php
$sender = "my_name";
$sendermail = "my@email_address.com";  
$recipient = "how do I enter all found email addresses?";
$subject = "PHP ist toll";
$text = "Dear Madam or Sir, bla bla, have you faced any problems while ordering? Do you need any help or advice? If so, send us a message 

to $sendermail.";
mail($recipient, $subject, $text,
     "From: $sender <$sendermail>");
 ?>

 

For 3)

var $page_types = array(
		'Y' => 'sent',
		'N' => 'unsent',
);
???

 

not so good at php :-(

Link to comment
Share on other sites

Hi,

 

I am looking for a way to send automatic emails to customers that have created an account and who have put stuff into the shopping cart but haven't checked out. So basically, it is a script that asks possible customers if they have had any problems or questions. Does something like that already exist? With language support?

 

Thx guys,

compuskill

 

Check the recover cart sales module

http://www.oscommerce.com/community/contributions,1688

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...