I've been working on getting email invoices working with paypal standard too, I'm using fancier-invoice-packing-slip-for-231 module ( http://addons.oscommerce.com/info/8362 )
The email is sent but on the invoice for paying via paypal the order number isn't appearing, yet it does on the cash on delivery invoice. Both use exactly the same code to generate the invoice. The code that sends the email is (lines 106-111 in email_invoice.php) :-
$ei_message->build_message(); $ei_message->send($order2->customer['name'], $order2->customer['email_address'], STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, 'Your Sanctuary Books Order # ' . $insert_id); if (SEND_EXTRA_ORDER_EMAILS_TO != '') { $ei_message->send('Orders','
[email protected]', STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, 'New Order Received # ' . ' ' . $insert_id);
By changing the $insert_id to '123456' the subject line shows the order number as 123456, hence the variable $insert_id should be the order number, but isn't been assigned the order number for some reason. Any ideas or suggestions would be welcome, Paul