[TIP / TRICK] Tell A Friend Reporting
#21
Posted 21 April 2003 - 10:30 PM
Warren
#22
Posted 22 April 2003 - 09:57 AM
#23
Posted 21 July 2003 - 03:13 PM
[img]http://www.nrgreen.com/nrgreenerror1.jpg[/img]
#24
Posted 21 July 2003 - 04:24 PM
But I wouldn't want to paint it!"
Stephen Wright
#25
Posted 24 July 2003 - 06:27 AM
for anyone who has made the silent email modification, any feedback on whether customers use it and how useful it is in generating leads?
Ben Daughtry
Dachitech Software
www.dtechsoftware.com
#26
Posted 29 July 2003 - 12:01 AM
I am running on MS2, and in case some of you are also running on MS2 and not getting the personal message showing up in the "silent report", here is the simple fix.
In mattice code, change the the following line:
$report .= "n" . 'Personal message: ' . "nn" . $HTTP_POST_VARS['yourmessage'];
to
$report .= "n" . 'Personal message: ' . "nn" . $HTTP_POST_VARS['message'];
Hope this helps
#27
Posted 29 July 2003 - 10:20 PM
As of right now, I have no clue where to add your code. The place where you say to add it, no longer exists in the MS2 code.
Thanks,
Priest
#28
Posted 30 July 2003 - 12:37 AM
Find this in catalog/tella_friend.php: (Approx lines 77 - 80)
$email_body .= sprintf(TEXT_EMAIL_LINK, tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $HTTP_GET_VARS['products_id'])) . "nn" . sprintf(TEXT_EMAIL_SIGNATURE, STORE_NAME . "n" . HTTP_SERVER . DIR_WS_CATALOG . "n"); tep_mail($to_name, $to_email_address, $email_subject, $email_body, $from_name, $from_email_address);Add this after above:
/* CC Tell a Friend - BOF */
// Mail a (silent) report to the web owner:
// get ip
if (getenv('HTTP_X_FORWARDED_FOR')) {
$ip=getenv('HTTP_X_FORWARDED_FOR');
} else {
$ip=getenv('REMOTE_ADDR');
}
// build report
$report = 'Here are the details of the Tell A Friend submission by ' . $from_name . ' on ' . date("D M j G:i:s Y") . ':';
$report .= "nn" . 'Sender details: ' . $from_name . ' - ' . $from_email_address;
$report .= "nn" . 'Recipient details: ' . $to_name . ' - ' . $to_email_address;
$report .= "nn" . 'Sender IP address: ' . $ip;
$report .= "nn" . 'Personal message: ' . "nn" . $message;
$report .= "nn" . 'Product link: ' . HTTP_SERVER . DIR_WS_CATALOG . FILENAME_PRODUCT_INFO . '?products_id=' . $HTTP_GET_VARS['products_id'];
// mail report
tep_mail('Tell A Friend', 'you@youraddress.com', '[ REPORT ] Tell a Friend Usage', tep_output_string_protected($report), $from_name, $from_email_address);
/* CC Tell a Friend - EOF */
Let me know how you go...
Tony
#29
Posted 03 August 2003 - 08:25 AM
Thanks TB
#30
Posted 03 August 2003 - 08:41 AM
All credit goes to Mattice for his original submission...
Tony
#31
Posted 03 August 2003 - 09:52 AM
here is the code again
/* CC Tell a Friend - BOF */
// Mail a (silent) report to the web owner:
// get ip
if (getenv('HTTP_X_FORWARDED_FOR')) {
$ip=getenv('HTTP_X_FORWARDED_FOR');
} else {
$ip=getenv('REMOTE_ADDR');
}
// build report
$report = 'Here are the details of the Tell A Friend submission by ' . $from_name . ' on ' . date("D M j G:i:s Y") . ':';
$report .= "nn" . 'Sender details: ' . $from_name . ' - ' . $from_email_address;
$report .= "nn" . 'Recipient details: ' . $to_name . ' - ' . $to_email_address;
$report .= "nn" . 'Sender IP address: ' . $ip;
$report .= "nn" . 'Personal message: ' . "nn" . $message;
$report .= "nn" . 'Product Name: ' . $products_name = $product_info['products_name'];
$report .= "nn" . 'Product link: ' . HTTP_SERVER . DIR_WS_CATALOG . FILENAME_PRODUCT_INFO . '?products_id=' . $HTTP_GET_VARS['products_id'];
// mail report
tep_mail('Tell A Friend', 'farrukh@arabianbazaar.com', '[ REPORT ] Tell a Friend Usage', tep_output_string_protected($report), $from_name, $from_email_address);
/* CC Tell a Friend - EOF */
#32
Posted 04 August 2003 - 04:13 PM
Is there maybe something else I need to turn on in the admin settings?
Thanks,
Priest
#33
Posted 04 August 2003 - 05:37 PM
Quote
tep_mail('Tell A Friend', '[b]farrukh@arabianbazaar.com Tell a Friend Usage', tep_output_string_protected($report), $from_name, $from_email_address);
/* CC Tell a Friend - EOF */
If not... this could be a reason you're not getting the e-mails.
Cheers,
Tony
#34
Posted 04 August 2003 - 06:26 PM
~P~
#35
Posted 04 August 2003 - 06:40 PM
Admin > Configuration > E-Mail Options > Send E-Mails > true
I am running the above code on my site, and I have tested it many times. Its working perfectly fine.
#36
Posted 04 August 2003 - 06:46 PM
INSERT INTO configuration (configuration_id, configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function) VALUES ('', 'Send To A Friend - Control ON/OFF', 'CONFIG_SEND_TO_A_FRIEND', 'true', 'Would you like to get an email when a visitor uses Send To A Friend ?', 12, 800, '2003-03-14 12:20:07', '2003-03-14 12:20:07', NULL, 'tep_cfg_select_option(array('true', 'false'),');
INSERT INTO configuration (configuration_id, configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function) VALUES ('', 'Send To A Friend - Email', 'EMAIL_SEND_TO_A_FRIEND', 'your email', 'Send an Email to this address when someone uses Send to a friend option', 12, 801, '2003-03-14 12:20:07', '2003-03-14 12:20:07', NULL, NULL);
Thanks to Druide for the above mysql code.
it will give you option under E-mail options in Configuration. You can enter the email where you want the report to be send.
Also, try to send the file "tell_a_friend.php" by email.
#37
Posted 01 September 2003 - 04:23 PM
anyone have any idea why it isnt sending in HTML even though I have it specified to do so?
thanks in advance...
#38
Posted 15 November 2003 - 11:15 PM
#39
Posted 16 November 2003 - 12:47 PM
I was wondering if this mod had been packaged up and put in the contribs section (with compatibility for those of us on MS2 as well)? I'm totally php stupid and I'd need a line by line "Khim - do this... Khim.. do that" or I'd seriously screw it up.
If it has been added to the contribs area, what is the name of the contrib so I can get this and install it on my shop?
Thanks in advance for writing the mod and for any light you can shed on this subject :-)
Khim~
#40
Posted 24 November 2003 - 12:49 PM









