era4eva Posted September 4, 2012 Posted September 4, 2012 I am trying to implement the Shopping Cart Tooltip addon: http://www.oscommerce.com/community/contributions,6789 However I am not getting any popups. I've changed "Display Cart After Adding Product" to false in Admin, Copied respective code to "stylesheet.css" "footer.php" and "english.php". Tried several times, even with a un-modified versions of Oscommerce2.3, still cannot get any pop-ups to occur. Does anyone have any ideas? I'm extremely unfamiliar with php and have no idea where to start in terms of debugging. I've attached the 3 edited files. Thanks in advance! english.php footer.php stylesheet.css Quote
1qay1qay Posted May 26, 2013 Posted May 26, 2013 Shopping Cart as Tooltip for osCommerce Online Merchant v2.2 will not work on youre version 2.3 Quote Baterije & Akumulatorji OsCommerce store
frankl Posted October 30, 2013 Posted October 30, 2013 Uploaded for 2.3.3.4 (not sure if it works on earlier versions) http://addons.oscommerce.com/info/8934 Quote osCommerce user since 2003!
TQ2013 Posted November 7, 2013 Posted November 7, 2013 Hi frank, I really appreciate the work you're putting in for this. I've added the changes according to your most recent update, but nothing's happening when I add an item to my cart. I've tried in Chrome and IE, and neither has had any sort of pop-up happen. I haven't made any other changes to the site really, and I've double checked that display cart after adding items is off. Any thoughts? Quote
frankl Posted November 27, 2013 Posted November 27, 2013 Hi Ed Did you see "This addon only works if "Display Cart After Adding Product" in Admin/Configuration/My Store is set to false"? If so let me know your site address and I can take a look. Quote osCommerce user since 2003!
aurelou Posted September 29, 2014 Posted September 29, 2014 Hi, Sorry for my english. I'm trying to install the addon on my 2.3.4 version and nothing happens. I don't know if it's because I'm using an addon for a 2.3.4.4 version (which is not mine), or if I put the code of footer.php in the wrong place because my footer's text also desapeared. I put this code at the very end of footer.php : <!-- BOF - -= Cart on Product Page =- (This line only in Product Info, leave out in stylesheet) //--><div id="popCart_overlay" onclick="document.getElementById('popCart').style.display='none'; document.getElementById('popCart_overlay').style.display='none'; return false;"></div><div id="popCart"><?phpif (tep_session_is_registered('new_products_id_in_cart')) {?><h4><?php echp PRODUCT_ADDED; ?></h4><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?><ul class="popcartList"><?php $cart_contents_string = ''; if ($cart->count_contents() > 0) { $products = $cart->get_products(); for ($i=0, $n=sizeof($products); $i<$n; $i++) { $cart_contents_string .= '<li><table width="100%"><tr><td>'; $cart_contents_string .= $products[$i]['quantity'] . ' x <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $products[$i]['id']) . '">'; $cart_contents_string .= $products[$i]['name'] . '</a></td>'; $products_tax = tep_get_tax_rate($products[$i]['tax_class_id']); $popup_price = $currencies->calculate_price($products[$i]['final_price'], $products_tax, $products[$i]['quantity']); $cart_contents_string .= '<td style="text-align: right; padding: 1px;" width="20%">' . $currencies->format($popup_price) . '</td></tr></table></li>'; } }echo $cart_contents_string;echo tep_draw_separator('pixel_black.gif', '100%', '1');echo '<li style="text-align: right; padding: 1px;"><b>Total: ' . $currencies->format($cart->show_total()) . '</b></li>';?></ul><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?><ul class="popcartList"><li class="popcartButton"> <?php echo '<a href="javascript:void(0);" onclick="document.getElementById(\'popCart\').style.display=\'none\'; document.getElementById(\'popCart_overlay\').style.display=\'none\'; return false;">' . tep_draw_button(IMAGE_BUTTON_CONTINUE, 'triangle-1-e') . '</a></li><li class="popcartButton"><a href="' . tep_href_link(FILENAME_SHOPPING_CART, '', 'SSL') . '">' . tep_draw_button(HEADER_TITLE_CART_CONTENTS . ($cart->count_contents() > 0 ? ' (' . $cart->count_contents() . ')' : ''), 'cart', tep_href_link(FILENAME_SHOPPING_CART)) . '</a></li><li class="popcartButton"><a href="' . tep_draw_button(HEADER_TITLE_CHECKOUT, 'triangle-1-e', tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL')) . '</a>' ?></li></ul><script type="text/javascript">var item=document.getElementById("popCart");function pop(el){ if(el.style.display=="block"){ el.style.display="none"; }else{ el.style.display="block"; } }pop(item);</script><script type="text/javascript">var item=document.getElementById("popCart_overlay");function overlay(el){ if(el.style.display=="block"){ el.style.display="none"; }else{ el.style.display="block"; } }overlay(item);</script><?phptep_session_unregister('new_products_id_in_cart');}?></div><!-- EOF - -= Cart on Product Page =- //--> Thanks very much for help. Quote
♥Tsimi Posted September 30, 2014 Posted September 30, 2014 (edited) your footer disappeared because of this <h4><?php echp PRODUCT_ADDED; ?></h4> change echp to echo that should bring the footer back but this add-on still won't work with 2.3.4. I tested it with 2.3.3.4 and it worked but it won't with 2.3.4. No clue why... Edited September 30, 2014 by Tsimi Quote
aurelou Posted September 30, 2014 Posted September 30, 2014 Thank you very much for your answer. I corrected the mistake of echo, the footer reapreared but you're right, it still doesn't work... If someone has a solution or another addon like this it would be great ! Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.