♥raiwa Posted June 10, 2018 Share Posted June 10, 2018 Uploaded update: Version 4.6.1. BS Changes: - Updated PHP 7.2 deprecated each() function in recently_viewed.php valquiria23 1 Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
lucsangel Posted October 31, 2018 Share Posted October 31, 2018 Hello, I have your most recent version installed on Frozen and get this error with php 7.2 : Warning: count(): Parameter must be an array or an object that implements Countable in /xxx/xx/xx/xx/catalog/includes/modules/content/shopping_cart/cm_sc_continue_recently_viewed.php on line 66 Line 65-69 are: $back = sizeof($navigation->path)-2; $count = count($products); if( isset($products[$count-1]['id']) ) { $continueButtonId = tep_get_product_path(str_replace(strstr($products[$count-1]['id'], '{'), '', $products[$count-1]['id'])); } Any ideas would be greatly appreciated. Barbara Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted October 31, 2018 Share Posted October 31, 2018 (edited) @lucsangel Hello Barbara, Please change line 66 to: $count = isset($products)? count($products) : 0; Edited October 31, 2018 by raiwa Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
lucsangel Posted October 31, 2018 Share Posted October 31, 2018 Thank You ! Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted November 4, 2018 Share Posted November 4, 2018 Updated with the above PHP 7.2 warning error fix: Version 4.6.2 BS Changes: - Fixed PHP 7.2 warning error in cm_sc_continue_recently_viewed.php shopping cart module. Thanks to @lucsangel for the report https://apps.oscommerce.com/z7iA8&recently-viewed-products-bs Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
Demitry Posted December 28, 2018 Share Posted December 28, 2018 hi Rainer, This is a small modification to this addon for anyone who wants to use it,.. and if you see value in it, you could add it to an update release. The mod is designed to only show the “See More” button if the number of recently viewed products exceeds the content limit of recently viewed products for each module. For example: if a customer viewed 4 or less products and the content limit is set to 4 recently viewed products, then it does not makes sense to have them see and click on a "See More" button that takes them to a Recently Viewed Products page containing the same 4 or less products that were listed on whatever page they were on. So, here are the changes and I’m only going to use the product_info page Recently Viewed module in this sample. This works in BS Edge. /includes/modules/content/index/cm_i_recently_viewed.php 1) FIND this code: // Set up the product data string in order by $recently_viewed_array if ($num_products > 0) { // Show only if we still have products in the array ADD just ABOVE it: // this will show/hide the "See More" button $rv_btn = 'style="display:none;"'; $rv_number_viewed = substr_count($recently_viewed_string, ",") + 1; if ($rv_number_viewed > MODULE_CONTENT_INDEX_RECENTLY_VIEWED_CONTENT_LIMIT) { $rv_btn = 'style="display:inline;"'; } 2) FIND this code: $recently_viewed_content .= '<h3 class="h3"><span itemprop="name">' . MODULE_CONTENT_INDEX_RECENTLY_VIEWED_TITLE . '</span>' . ((MODULE_CONTENT_INDEX_RECENTLY_VIEWED_SHOW_MORE_BUTTON == 'True')? ' <a href="' . tep_href_link('recently_viewed.php') . '" class="btn btn-default btn-sm">' . MODULE_CONTENT_INDEX_RECENTLY_VIEWED_IMAGE_BUTTON_SEE_MORE . ' <span class="fa fa-angle-right"></span></a>' : '' ) . '</h3>'; REPLACE it with this: $recently_viewed_content .= '<h3><span itemprop="name">' . MODULE_CONTENT_INDEX_RECENTLY_VIEWED_TITLE . '</span>' . ((MODULE_CONTENT_INDEX_RECENTLY_VIEWED_SHOW_MORE_BUTTON == 'True')? ' <span ' . $rv_btn . '>' . tep_draw_button(MODULE_CONTENT_INDEX_RECENTLY_VIEWED_IMAGE_BUTTON_SEE_MORE, 'glyphicon glyphicon-triangle-right', tep_href_link('recently_viewed.php'), 'primary', null, 'btn-default btn-sm') . '</span>':'') . '</h3>'; Quote osCommerce: made for programmers, ...because store owners do not want to be programmers. https://trends.google.com/trends/explore?date=all&geo=US&q=oscommerce Link to comment Share on other sites More sharing options...
♥raiwa Posted December 28, 2018 Share Posted December 28, 2018 Thank you @Demitry I'll have a look and include it in the next update. Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
Guest Posted March 6, 2019 Share Posted March 6, 2019 @raiwa - Is there a module available to put Recently Viewed in the navigation bar? I'm trying to minimize the use of infoboxes and make the pages less cluttered. I've tried the header module, but just can't get happy with how it looks. A link in the navigation bar would be better. Thank You! - Andrea Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted March 7, 2019 Share Posted March 7, 2019 Hello Andrea @puggybelle, Navbar module is not available yet. I'll see if I find some time to add it. I believe it wouldn't be complicate to use the header module's coding and create the navbar module. Maybe you can try. Best regards Rainer Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
Roaddoctor Posted April 5, 2019 Share Posted April 5, 2019 Hello all, I'm using the non BS (2.3.4) version and all is well.... except when the rare visitor happens to enter the site directly using https://www.domain.com/recently_viewed.php. the result is a soft 404 page Recently Viewed Products you have recently viewed 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') and p.products_id = pd.products_id and pd.language_id = '1'' at line 1 select count(*) as total from products p left join manufacturers m on (p.manufacturers_id = m.manufacturers_id), products_description pd where p.products_status = '1' and p.products_id IN () and p.products_id = pd.products_id and pd.language_id = '1' [TEP STOP] I'm pretty sure here is what needs sorting $viewed = implode(",", array_unique($navigation->products)); if (sizeof($viewed) == 0) { tep_redirect(tep_href_link(FILENAME_PRODUCTS_NEW)); } here is the entire recently_viewed.php <?php /* $Id$ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2013 osCommerce Released under the GNU General Public License */ require('includes/application_top.php'); require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_RECENTLY_VIEWED); $breadcrumb->add(NAVBAR_TITLE, tep_href_link(FILENAME_RECENTLY_VIEWED)); $viewed = implode(",", array_unique($navigation->products)); if (sizeof($viewed) == 0) { tep_redirect(tep_href_link(FILENAME_PRODUCTS_NEW)); } require(DIR_WS_INCLUDES . 'template_top.php'); ?> <h1><?php echo HEADING_TITLE; ?></h1> <h2><?php echo HEADING_SUBTITLE; ?></h2> <div class="contentContainer"> <div class="contentText"> <?php $products_new_array = array(); $products_new_query_raw = "select p.products_id, pd.products_name, p.products_image, p.products_price, p.products_tax_class_id, p.products_date_added, m.manufacturers_name from " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m on (p.manufacturers_id = m.manufacturers_id), " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id IN (" . $viewed . ") and p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' ORDER BY FIELD(p.products_id, " . $viewed . ")"; $products_new_split = new splitPageResults($products_new_query_raw, MAX_DISPLAY_PRODUCTS_NEW); if (($products_new_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3'))) { ?> <div> <span style="float: right;"><?php echo TEXT_RESULT_PAGE . ' ' . $products_new_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></span> <span><?php echo $products_new_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS_VIEWED); ?></span> </div> <br /> <?php } ?> <?php if ($products_new_split->number_of_rows > 0) { ?> <table border="0" width="100%" cellspacing="2" cellpadding="2"> <?php $products_new_query = tep_db_query($products_new_split->sql_query); while ($products_new = tep_db_fetch_array($products_new_query)) { if ($new_price = tep_get_products_special_price($products_new['products_id'])) { $products_price = '<del>' . $currencies->display_price($products_new['products_price'], tep_get_tax_rate($products_new['products_tax_class_id'])) . '</del> <span class="productSpecialPrice">' . $currencies->display_price($new_price, tep_get_tax_rate($products_new['products_tax_class_id'])) . '</span>'; } else { $products_price = $currencies->display_price($products_new['products_price'], tep_get_tax_rate($products_new['products_tax_class_id'])); } // PRODUCTS SHIP FREE START $freeship_str = ''; if(tep_products_ship_free_check($products_new['products_id'])) $freeship_str = '<span class="freeShipSm">(' . TEXT_PRODUCT_SHIPS_FREE . ')</span>'; // PRODUCTS SHIP FREE END // added to below for Products Ship Free: . ' ' . $freeship_str ?> <tr> <td width="<?php echo SMALL_IMAGE_WIDTH + 10; ?>" valign="top" class="main"><?php echo '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $products_new['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $products_new['products_image'], $products_new['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a>'; ?></td> <td valign="top" class="main"><?php echo '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $products_new['products_id']) . '"><strong><u>' . $products_new['products_name'] . '</u></strong></a><br />' . TEXT_DATE_ADDED . ' ' . tep_date_long($products_new['products_date_added']) . '<br />' . TEXT_MANUFACTURER . ' ' . $products_new['manufacturers_name'] . '<br /><br />' . TEXT_PRICE . ' ' . $products_price . ' ' . $freeship_str; ?></td> <!--<td align="right" valign="middle" class="smallText"><?php // echo tep_draw_button(IMAGE_BUTTON_IN_CART, 'cart', tep_href_link(FILENAME_PRODUCTS_NEW, tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $products_new['products_id'])); ?></td>--> <!--// BOF: MOD - EASY CALL FOR PRICE 2.3.1v1.1--> <td align="right" valign="middle" class="prixST"> <?php $products_price_tmp = preg_match_all('/([\d]+)/', $products_price, $match); if ((int)$products_price_tmp > 0){ echo tep_draw_button(IMAGE_BUTTON_IN_CART, 'cart', tep_href_link(FILENAME_RECENTLY_VIEWED, tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $products_new['products_id'])); } else echo $products_price ; ?></td> <!--// EOF: MOD - EASY CALL FOR PRICE 2.3.1v1.1--> </tr> <?php } ?> </table> <?php } else { ?> <div> <?php echo TEXT_NO_VIEWED_PRODUCTS; ?> </div> <?php } if (($products_new_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3'))) { ?> <br /> <div> <span style="float: right;"><?php echo TEXT_RESULT_PAGE . ' ' . $products_new_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></span> <span><?php echo $products_new_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS_VIEWED); ?></span> </div> <?php } ?> </div> </div> <?php require(DIR_WS_INCLUDES . 'template_bottom.php'); require(DIR_WS_INCLUDES . 'application_bottom.php'); ?> any assistance appreciated. Dave Quote -Dave Link to comment Share on other sites More sharing options...
♥raiwa Posted August 18, 2019 Share Posted August 18, 2019 Updated for Phoenix 1.0.2.0. https://apps.oscommerce.com/z7iA8&recently-viewed-products-bs Compatibility: Phoenix 1.0.2.x PHP: 7.0-7.3 ********************************************************************************************************************* This version has not been tested with earlier Phoenix versions. You will need to apply at least the following database update to use it with Phoenix 1.0.0.x or 1.0.1.x.:https://pastebin.com/Ed8B6nuT You may also need to update custom.css ********************************************************************************************************************* Changes: - updated to Phoenix 1.0.2.x - replaced ht-module with sidewide hook - updated coding to match Phoenix 1.0.2.0 product listings and config entries - simplified modules and removed config entries to show always product name, image and price - simplified description length limit Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
♥raiwa Posted August 19, 2019 Share Posted August 19, 2019 Upddated to Version 5.0.1 Phoenix https://apps.oscommerce.com/z7iA8&recently-viewed-products-bs Compatibility: Phoenix 1.0.2.x PHP: 7.0-7.3 ********************************************************************************************************************* This version has not been tested with earlier Phoenix versions. You will need to apply at least the following database update to use it with Phoenix 1.0.0.x or 1.0.1.x.:https://pastebin.com/Ed8B6nuT You may also need to update custom.css ********************************************************************************************************************* Changes: - modified "See More" button to show only if more recently products have been visited than number of recently products shown in module. Thanks to @Demitry for the suggestion - readded missing truncate text function in cm_sc_continue_recently_viewed.php shopping cart module - removed obsolete truncate text functions in box module valquiria23 and Demitry 2 Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
Denzel Posted November 24, 2019 Share Posted November 24, 2019 Hi @raiwa, Could it be that this is no longer working with phoenix? It looks like Gary has changed the product_listing module in v1.0.3.0. I have no more Images in the listing. The Box works, but the Imagepath in the listing is empty. Only "images/". Can you confirm this, or is it a bug at my testshop ? Regards, Denzel. Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted November 24, 2019 Share Posted November 24, 2019 (edited) 21 minutes ago, Denzel said: Hi @raiwa, Could it be that this is no longer working with phoenix? It looks like Gary has changed the product_listing module in v1.0.3.0. I have no more Images in the listing. The Box works, but the Imagepath in the listing is empty. Only "images/". Can you confirm this, or is it a bug at my testshop ? Regards, Denzel. Recently Viewed Products (sales optimized) for OSCOM CE Phoenix Compatibility: Phoenix 1.0.2.x PHP: 7.0-7.3 Not yet updated to Phoenix 1.0.3.x. It should not be too complicate if you compare with the core product module. EDIT: Just checked and the mayor product listing update was introduced in Phoenix 1.0.2.0 , so there must be another issue. I'll test with 1.0.3.0 when I'll find some time. Edited November 24, 2019 by raiwa Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
♥raiwa Posted November 24, 2019 Share Posted November 24, 2019 Just checked with Phoenix 1.0.3.0 and all works fine. Must be something with your store. Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
♥Heatherbell Posted November 24, 2019 Share Posted November 24, 2019 8 minutes ago, raiwa said: Just checked with Phoenix 1.0.3.0 and all works fine. Works in our 1.0.3.0 shops too. raiwa 1 Quote Link to comment Share on other sites More sharing options...
Denzel Posted November 24, 2019 Share Posted November 24, 2019 I got it: In 1.0.3.0 in admin->modules->product listing the Image option is empty by default. As the function is marked as defunct, I don't care about. I've changed it to "1" and voilà: Images appears 😎 If burt has planned to delete the function, this must be adjusted somewhere in the contrib ... Regards, Denzel. Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted January 20, 2020 Share Posted January 20, 2020 Upddated to Version 5.0.2 Phoenix, tested with Phoenix 1.0.4.3 Recently Viewed Products Phoenix Changes: - removed deprecated "Product Image" configuration setting - updated database query in recently_viewed.php radhavallabh and domiosc 2 Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
radhavallabh Posted February 18, 2020 Share Posted February 18, 2020 (edited) On 1/20/2020 at 11:02 PM, raiwa said: Upddated to Version 5.0.2 Phoenix, tested with Phoenix 1.0.4.3 Recently Viewed Products Phoenix Changes: - removed deprecated "Product Image" configuration setting - updated database query in recently_viewed.php Hi , Thank you for this wonderful addon; I use Oscommerce 1.0.5.0 Phoenix with multiple languages- English, German, Spanish I face a issue the products shown in the recently viewed are in all 3 languages together.. When I view the catalog in English----The recently viewed addon shows a product in english, german and spanish in 3 separate boxes of the row. Please help on how to fix it; Regds./ radhavallabh Edited February 18, 2020 by radhavallabh Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted February 19, 2020 Share Posted February 19, 2020 23 hours ago, radhavallabh said: Hi , Thank you for this wonderful addon; I use Oscommerce 1.0.5.0 Phoenix with multiple languages- English, German, Spanish I face a issue the products shown in the recently viewed are in all 3 languages together.. When I view the catalog in English----The recently viewed addon shows a product in english, german and spanish in 3 separate boxes of the row. Please help on how to fix it; Regds./ radhavallabh Hello, I checked on my multilanguage test store and all shows correct. Can you please post a screenshot and/or PM the link to the store. rgds Rainer Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
radhavallabh Posted February 20, 2020 Share Posted February 20, 2020 18 hours ago, raiwa said: Hello, I checked on my multilanguage test store and all shows correct. Can you please post a screenshot and/or PM the link to the store. rgds Rainer I am currently installing on Xampp Server.. Attaching a screenshot of it.. Hope to fix it... Thank you in advance for your valuable help and reply; Regds./ radhavallabh Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted February 20, 2020 Share Posted February 20, 2020 Please check if you have the same problem in your new products module. The recently products module is correct coded for multilanguage store. It must be something with your store setup. Just to be sure, you didn't change anything in the recently products module? Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
radhavallabh Posted February 20, 2020 Share Posted February 20, 2020 55 minutes ago, raiwa said: Please check if you have the same problem in your new products module. The recently products module is correct coded for multilanguage store. It must be something with your store setup. Just to be sure, you didn't change anything in the recently products module? Hi; The New Products module works perfectly; I did not make any change to the Recently Viewed module it is same core install as on the latest version.😟 Attaching screenshot of the New Products. Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted February 20, 2020 Share Posted February 20, 2020 Quote it is same core install as on the latest version Which versions are we talking about: Phoenix and recently viewed? I can't research further on this without access to your store. Quote About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
radhavallabh Posted February 20, 2020 Share Posted February 20, 2020 1 minute ago, raiwa said: Which versions are we talking about: Phoenix and recently viewed? I can't research further on this without access to your store. 1.0.5.0 Phoenix and 5.0.2 Recently Viewed Quote Link to comment Share on other sites More sharing options...
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.