E-Mail-Benachrichtigung bei neuem Artikel
Aus Wiki | xtcModified eCommerce Shopsoftware
Gibt es eine einfache Funktion oder ein Codeschnipsel, mit dem man eine E-Mail-Benachrichtigung an eine hinterlegte E-Mailadresse senden kann, wenn ein neuer Artikel im Shop aufgenommen wurde? (Hintergrund: könnte damit meinen Blog automatisch feeden).
von hendrik am Do 3. Sep 2009, 13:50
admin/includes/classes/categories.php, Zeile 726 ca.
Finde:
} // insert_product ends
Füge davor ein:
// mail beginn --------------------------------- require_once(DIR_FS_CATALOG.DIR_WS_CLASSES.'class.phpmailer.php'); require_once(DIR_FS_INC . 'xtc_php_mail.inc.php'); $from_email_address = STORE_OWNER_EMAIL_ADDRESS; $from_email_name = STORE_NAME; $to_email_address = 'blog@sonstwo.de'; $to_name = 'blogmail'; $forwarding_to = ''; $reply_address = ''; $reply_address_name = ''; $path_to_attachement = ''; $path_to_more_attachements = ''; $email_subject = 'Neuer Artikel eingestellt'; $message_body_html = 'Heiße Info!<br>Der Laden '.STORE_NAME.' hat was neues!'; $message_body_plain= "Heiße Info!\nDer Laden ".STORE_NAME." hat was neues!"; xtc_php_mail( $from_email_address, $from_email_name, $to_email_address, $to_name, $forwarding_to, $reply_address, $reply_address_name, $path_to_attachement, $path_to_more_attachements, $email_subject, $message_body_html, $message_body_plain ); // mail end ------------------------------

