Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

PayPal IPN & Customer-email


guicher

Recommended Posts

Hi,

 

first of all...I thinks this is sublime mod. But I ran into a error wich I can't resolve cause my PHP knowlege is insufficient.

 

I use Fancier_Invoice_&_Packingslip_v6.2_1 with my osC shop and everything was working fine. But when I integrated this package with osCommmerce_PayPal_IPN_v1.2 the email the customer recieved contained an error wich is as follows;

 

Warning: htmlspecialchars() expects parameter 1 to be string, array given in /data/members/paid/s/y/sylviesoriginals.nl/htdocs/www/includes/functions/general.php on line 46

 

Warning: htmlspecialchars() expects parameter 1 to be string, array given in /data/members/paid/s/y/sylviesoriginals.nl/htdocs/www/includes/functions/general.php on line 46

 

Please help....

 

 

This is the code in paypal_ipn.php wich I've changed:

 

// lets start with the email confirmation

 

// START HTML Invoice

 

if (EMAIL_INVOICE == 'true') {

require(DIR_WS_MODULES . EMAIL_INVOICE_DIR . FILENAME_EMAIL_INVOICE);

} else {

// END HTML Invoice

 

$email_order = STORE_NAME . "\n" .

EMAIL_SEPARATOR . "\n" .

EMAIL_TEXT_ORDER_NUMBER . ' ' . $order_id . "\n" .

EMAIL_TEXT_INVOICE_URL . ' ' . tep_href_link(FILENAME_ACCOUNT_HISTORY_INFO, 'order_id=' . $order_id, 'SSL', false) . "\n" .

EMAIL_TEXT_DATE_ORDERED . ' ' . strftime(DATE_FORMAT_LONG) . "\n\n";

if ($order->info['comments']) {

$email_order .= tep_db_output($order->info['comments']) . "\n\n";

}

$email_order .= EMAIL_TEXT_PRODUCTS . "\n" .

EMAIL_SEPARATOR . "\n" .

$products_ordered .

EMAIL_SEPARATOR . "\n";

 

for ($i=0, $n=sizeof($order_totals); $i<$n; $i++) {

$email_order .= strip_tags($order_totals[$i]['title']) . ' ' . strip_tags($order_totals[$i]['text']) . "\n";

}

 

if ($order->content_type != 'virtual') {

$email_order .= "\n" . EMAIL_TEXT_DELIVERY_ADDRESS . "\n" .

EMAIL_SEPARATOR . "\n" .

tep_address_label($customer_id, $sendto, 0, '', "\n") . "\n";

}

 

$email_order .= "\n" . EMAIL_TEXT_BILLING_ADDRESS . "\n" .

EMAIL_SEPARATOR . "\n" .

tep_address_label($customer_id, $billto, 0, '', "\n") . "\n\n";

 

if (is_object($$payment)) {

$email_order .= EMAIL_TEXT_PAYMENT_METHOD . "\n" .

EMAIL_SEPARATOR . "\n";

$payment_class = $$payment;

$email_order .= $payment_class->title . "\n\n";

if ($payment_class->email_footer) {

$email_order .= $payment_class->email_footer . "\n\n";

}

}

 

tep_mail($order->customer['firstname'] . ' ' . $order->customer['lastname'], $order->customer['email_address'], EMAIL_TEXT_SUBJECT, $email_order, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS);

 

// send emails to other people

if (SEND_EXTRA_ORDER_EMAILS_TO != '') {

tep_mail('', SEND_EXTRA_ORDER_EMAILS_TO, EMAIL_TEXT_SUBJECT, $email_order, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS);

}

 

// START HTML Invoice

}

// END HTML Invoice

// load the after_process function from the payment modules

Link to comment
Share on other sites

Hi there,

 

dispite the the changes I made after the tip of choosealogin I still get een error in de emails send to the customer after paying with the paypal module and Fancier Invoice....

 

Stil get the following error:

 

Warning: htmlspecialchars() expects parameter 1 to be string, array given in /data/members/paid/s/y/sylviesoriginals.nl/htdocs/www/includes/functions/general.php on line 46

 

Warning: htmlspecialchars() expects parameter 1 to be string, array given in /data/members/paid/s/y/sylviesoriginals.nl/htdocs/www/includes/functions/general.php on line 46

RG Computer Advising

Rene Guicherit

Waterviolier ***

********, 4823 MA

Noord-Brabant,

 

With other payment type this error doesn't occur only when paying with Paypal IPN module. Anyone can help?

 

Greetings Rene Guicherit

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...