Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Problems with Tell a Friend


rdbello

Recommended Posts

I modified the column right and when I installed the "Tell a Friend" box, the button sent to "add product" page. How can I fix it to sent the link to form?

 

Thanks

tell a friend box default or hacked? product page default or hacked?

 

for hacked pages, noone can comment unless seeing code

:-)

Monika

 

addicted to writing code ... can't get enough of databases either, LOL!

 

my toolbox: Textpad - Compare and Merge - phpMyAdmin - WS_FTP - Photoshop - How to search the forum

 

Interactive Media Award July 2007 ~ category E-Commerce

my advice on the forum is for free, PMs where you send me work are considered consultation which I charge for ...

Link to comment
Share on other sites

tell a friend box default or hacked? product page default or hacked?

 

for hacked pages, noone can comment unless seeing code

 

Hi Monika, thanks to answer me.

 

I tried to use original box and with a contribution too. I pasted the script from catalog/include/tell_a_friend.php bellow:

 

=====================================================

 

<?php

/*

$Id: tell_a_friend.php,v 1.14 2002/04/04 10:23:58 harley_vb Exp $

 

osCommerce, Open Source E-Commerce Solutions

http://www.oscommerce.com

 

Copyright © 2002 osCommerce

 

Released under the GNU General Public License

*/

?>

<!-- tell_a_friend //-->

<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">

<tr>

<td>

<TABLE class="lhssidebar" WIDTH=100% BORDER=0 CELLPADDING=0 CELLSPACING=0>

<TR>

<TD COLSPAN=0 ALIGN="CENTER" bgcolor="#1D365D"> <IMG SRC="images/boxes/table_notify.gif" WIDTH=173 HEIGHT=25></TD>

</TR>

<TR>

<td align="center">

<?php

$hide = tep_draw_hidden_field('products_id', $HTTP_GET_VARS['products_id']);

$hide .= tep_hide_session_id();

 

$info_box_contents = array();

$info_box_contents[] = array('form' => '<form name="tell_a_friend" method="get" action="' . tep_href_link(FILENAME_TELL_A_FRIEND, '', 'NONSSL', false) . '">',

'align' => 'left',

'text' => '<div align="center">' . tep_draw_input_field('send_to', '', 'size="15"') . ' ' . tep_image_submit('button_tell_a_friend.gif', BOX_HEADING_TELL_A_FRIEND) . $hide . '</div><br>' . BOX_TELL_A_FRIEND_TEXT

);

new infoBox($info_box_contents);

?>

</TD>

</TR>

<TR>

<TD COLSPAN=3>  </TD>

</TR>

</TABLE>

</td>

</tr>

<!-- tell_a_friend_eof //-->

========================================

 

If you'll need antohers scripts, tell me please.

 

Thanks

 

Renato

Link to comment
Share on other sites

if this is an included file and you included it above the add to cart button, the new form will not be used but the add to cart form. You cannot nest form ... this if included to the product_info.php (which i suppose you did) has to be below the button bar - or way above the bar with the add to cart form starting only below it, not at the top of the file as it's by default.

:-)

Monika

 

addicted to writing code ... can't get enough of databases either, LOL!

 

my toolbox: Textpad - Compare and Merge - phpMyAdmin - WS_FTP - Photoshop - How to search the forum

 

Interactive Media Award July 2007 ~ category E-Commerce

my advice on the forum is for free, PMs where you send me work are considered consultation which I charge for ...

Link to comment
Share on other sites

if this is an included file and you included it above the add to cart button, the new form will not be used but the add to cart form. You cannot nest form ... this if included to the product_info.php (which i suppose you did) has to be below the button bar - or way above the bar with the add to cart form starting only below it, not at the top of the file as it's by default.

 

Hi again,

 

I include bellow the suggestion box in the column_right page. This is the script from this page:

 

====================================================

<?php

/*

$Id: column_right.php,v 1.17 2003/06/09 22:06:41 hpdl Exp $

 

osCommerce, Open Source E-Commerce Solutions

http://www.oscommerce.com

 

Copyright © 2003 osCommerce

 

Released under the GNU General Public License

*/

 

include(DIR_WS_BOXES . 'sugestions.php');

 

//if (isset($HTTP_GET_VARS['products_id'])) {

if (basename($PHP_SELF) != FILENAME_TELL_A_FRIEND) {

include(DIR_WS_BOXES . 'tell_a_friend.php');

} else {

include(DIR_WS_BOXES . 'specials.php');

}

?>

 

============================================

 

Would you like to see the product_info page?

 

Thanks

 

Renato

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...