osCommerce and osCMax shopping cart software forums

Shopping Cart Software

osCommerce with teeth!

 
 

Tell a Friend Box??

This is a discussion on Tell a Friend Box?? within the osCMax v1.7 General Mods Discussion forums, part of the osCMax v1.7 Forums category; why is there a text input? It doesn't do anything, when you click the mail icon you still have to ...


Go Back   osCommerce and osCMax shopping cart software forums > osCMax v1.7 Forums > osCMax v1.7 General Mods Discussion

Register FAQ Members List Calendar Mark Forums Read


Free community membership! Fast easy FREE membership
Closed Thread

 

LinkBack Thread Tools
  #1  
Old 04-04-2004, 10:08 AM
Active Member
 
Join Date: Feb 2004
Posts: 174
Thanks: 0
Thanked 1 Time in 1 Post
Rep Power: 0
Kristine is an unknown quantity at this point
Default Tell a Friend Box??

why is there a text input? It doesn't do anything, when you click the mail icon you still have to enter the friends email address again? How can I get that outta there?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Sponsored Links
Advertisement
  #2  
Old 04-11-2004, 07:58 AM
Active Member
 
Join Date: Feb 2004
Posts: 174
Thanks: 0
Thanked 1 Time in 1 Post
Rep Power: 0
Kristine is an unknown quantity at this point
Default

I finally got it to work! I also added a little more to it if anyone is interested.
First off I fixed the problem of the text input box not working.
You can either have it carry forward the name of your friend or the friends email address. I have mine carrying the email address to the next page:
In catalog/includes/boxes find this:
Code:
text' => tep_draw_input_field('send_to', '', 'size="10"') . ' ' . tep_image_submit('button_tell_a_friend.gif', BOX_HEADING_TELL_A_FRIEND) . tep_draw_hidden_field('products_id', $HTTP_GET_VARS['products_id']) . tep_hide_session_id() . '<br>' . BOX_TELL_A_FRIEND_TEXT);
change 'send_to' to 'to_email_address'

You could also change it to 'to_name'

I found this in the wiki docs, whenever someone uses the tell a friend, it sends you a copy.

In catalog/tell_a_friend.php
find: around line 80
Code:
tep_mail($to_name, $to_email_address, $email_subject, $email_body, $from_name, $from_email_address); ?>
After that put this:
Code:
//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 T.A.F. submission by ' . $from_name . ' on ' . date("D M j G:i:s Y") . ':'; $report .= "\n\n" . 'Recipient details: ' . $HTTP_POST_VARS['to_name'] . ' - ' . $HTTP_POST_VARS['to_email_address']; $report .= "\n" . 'Sender details: ' . $from_name . ' - ' . $from_email_address; $report .= "\n" . 'Sender ip address: ' . $ip; $report .= "\n" . 'Personal message: ' . "\n\n" . $HTTP_POST_VARS['message']; $report .= "\n\n" . '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', stripslashes($report), '', $from_email_address);
I had to change the code a little from the original because it was not giving me all the detail it should. The original is here http://wiki.oscommerce.com/docsCatEmailFriend

Change you@youraddress.com to your email address.
Note that if you use MIME e-mail you should change all occurances of "\n" to "<br>"
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #3  
Old 04-26-2004, 09:31 PM
Anonymous
Guest
 
Posts: n/a
Default

Kristine ~

I seem to be having one of those days, (again;~) I implemented your addition to the TAF script and it works fine on the recipient side, but I'm having a heck of a time getting it to send me a report.

I've tried several valid emails, (yes, including my admin email and I still get no report.

Did you have any issues like this? If so, any hints as to the resolution?

Dave

(BTW, thanks for all your "other" input. You ask the right ?'s)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #4  
Old 04-26-2004, 09:39 PM
New Member
 
Join Date: Feb 2004
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
DaveF
Default

Oops - My log-in had timed out. Dave
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #5  
Old 05-03-2004, 06:19 AM
Active Member
 
Join Date: Feb 2004
Posts: 174
Thanks: 0
Thanked 1 Time in 1 Post
Rep Power: 0
Kristine is an unknown quantity at this point
Default

I'm sorry I didn't notice this reply till now.
I didn't have any problems, it sent me the report right from the start. I'm not sure what your problem might be.
Quote:
(BTW, thanks for all your "other" input. You ask the right ?'s)
Well I guess if you ask enough, you're bound to ask the right ones! LOL
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Sponsored Links
Advertisement
Closed Thread

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
Cannot tell a friend about articles jbanda osCMax v2 Features Discussion 0 08-17-2006 05:59 AM
Tell a Friend feature countingsheep osCMax v2 Customization/Mods 0 08-12-2006 10:16 AM
HTML email a friend adrenalinez osCommerce 2.2 Modification Help 0 09-03-2003 11:54 AM
Wierd return from 'Tip a friend' and more... Petter osCommerce 2.2 Installation Help 0 02-16-2003 04:58 AM
Email loaded shopping cart to a friend/client Anonymous osCommerce 2.2 Modification Help 2 11-25-2002 11:12 AM


All times are GMT -8. The time now is 03:39 PM.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO
http://www.oscmax.com/forums/
Copyright 2008 osCMax