♥BrockleyJohn 312 Posted March 29, 2017 No existing support thread that I can find... I just uploaded an updated version of this addon: - php7 compliant - doesn't use filenames.php - minimal core changes (one file) Addon is http://addons.oscommerce.com/info/8419 Also on github in a branch of Edge at https://github.com/BrockleyJohn/Responsive-osCommerce/tree/addon_ship2pay Contact me for work on updating existing stores - whether to Phoenix or the new osC when it's released. Looking for a payment or shipping module? Maybe I've already done it. Working on generalising bespoke solutions for Quickbooks integration, Easify integration and pay4later (DEKO) integration at 2.3.x Share this post Link to post Share on other sites
marcello 18 Posted May 8, 2017 (edited) Hey there John. Thanks for putting this together. I took a quick look a the code and noticed a few php notification that were generated due to not checking if variable isset. Attached is the modified code for the admin page.ship2pay.php Edited May 8, 2017 by marcello Share this post Link to post Share on other sites
♥BrockleyJohn 312 Posted May 12, 2017 Thanks Marcello, I'll take a look. I confess I didn't go far into testing the existing code or running with E_STRICT, I just whacked in a set of refinements and tested them! Contact me for work on updating existing stores - whether to Phoenix or the new osC when it's released. Looking for a payment or shipping module? Maybe I've already done it. Working on generalising bespoke solutions for Quickbooks integration, Easify integration and pay4later (DEKO) integration at 2.3.x Share this post Link to post Share on other sites
Omar_one 154 Posted November 7, 2018 Hello @BrockleyJohn Under php7.2 it give a PHP Warning: PHP Fatal error: Cannot redeclare class ship2pay in /home/shop/includes/classes/ship2pay.php on line 20 Br Omar Get the latest Responsive osCommerce CE (community edition) here . Share this post Link to post Share on other sites
♥BrockleyJohn 312 Posted November 7, 2018 @Omar_one that would be a fatal error at any php level How have you got two class declarations in the file? That usually occurs with modules when people upload the class file to the language directory, so I'm struggling to guess how you managed it. Contact me for work on updating existing stores - whether to Phoenix or the new osC when it's released. Looking for a payment or shipping module? Maybe I've already done it. Working on generalising bespoke solutions for Quickbooks integration, Easify integration and pay4later (DEKO) integration at 2.3.x Share this post Link to post Share on other sites
Omar_one 154 Posted November 7, 2018 I have no idea 😳 ..... there is class file in the language directory If I change the require('includes/classes/ship2pay.php'); to require_once('includes/classes/ship2pay.php'); the warring not show any more for that class it give another warring warring PHP Fatal error: Cannot redeclare class cod in /home/shop/includes/modules/payment/cod.php on line 13 Get the latest Responsive osCommerce CE (community edition) here . Share this post Link to post Share on other sites
Omar_one 154 Posted November 8, 2018 @BrockleyJohn I found why it give this warring because I have Modules Shopping Cart installed by @raiwa so if I uninstall it your module working with any warring.. Do you have idea how to make it working with that module ? Thank you Omar Get the latest Responsive osCommerce CE (community edition) here . Share this post Link to post Share on other sites
Omar_one 154 Posted November 8, 2018 after changing this line in Modules Shopping Cart module ... includes/modules/content/shopping_cart/cm_sc_checkout_alt.php .. include('includes/classes/payment.php'); to include_once('includes/classes/payment.php'); there is no warring, I don't know if it is the right fix !!! Br Omar 1 raiwa reacted to this Get the latest Responsive osCommerce CE (community edition) here . Share this post Link to post Share on other sites
♥BrockleyJohn 312 Posted November 8, 2018 @Omar_one I can't see any problem with your change, it should be fine Contact me for work on updating existing stores - whether to Phoenix or the new osC when it's released. Looking for a payment or shipping module? Maybe I've already done it. Working on generalising bespoke solutions for Quickbooks integration, Easify integration and pay4later (DEKO) integration at 2.3.x Share this post Link to post Share on other sites
♥raiwa 1,472 Posted November 8, 2018 @Omar_one, thats ok like John says. I'll apply this to the shopping cart module in the next update. Thank you! About Me: http://forums.oscommerce.com/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 Share this post Link to post Share on other sites
boelle 9 Posted October 14, 2019 would it be possible to have this work with Phoenix and no file changes at all? Quo plus habent, eo plus cupiunt Share this post Link to post Share on other sites
♥BrockleyJohn 312 Posted October 14, 2019 Up to now there is still no way to extend the payment class to restrict the selection on checkout_payment without modifying core code, so the modification to the constructor of the core class is the simplest way of doing it. If @raiwa's latest request for a hook in the payment form might be a way in if it gets anywhere. Contact me for work on updating existing stores - whether to Phoenix or the new osC when it's released. Looking for a payment or shipping module? Maybe I've already done it. Working on generalising bespoke solutions for Quickbooks integration, Easify integration and pay4later (DEKO) integration at 2.3.x Share this post Link to post Share on other sites
Omar_one 154 Posted October 17, 2020 @BrockleyJohn is there any plan to update it to Phoenix? Get the latest Responsive osCommerce CE (community edition) here . Share this post Link to post Share on other sites
Omar_one 154 Posted October 18, 2020 (edited) @BrockleyJohn I installed it and there was errors I fixed all of them except this one on the admin Notice: Undefined index: action in C:\xampp\htdocs\test\admin\ship2pay.php on line 108 and here is the line (on just this line there was 4 errors... fixed 3 of them and still the last one " this line after the editing ") if (((empty($_GET['s2p_id'])) || (empty($_GET['s2p_id'] == $s2p['s2p_id']))) && (empty($trInfo) && (substr($_GET['action'], 0, 3) != 'new'))) { here is the original line if (((!$_GET['s2p_id']) || (@$_GET['s2p_id'] == $s2p['s2p_id'])) && (!$trInfo) && (substr($_GET['action'], 0, 3) != 'new')) { any idea how to fix it ? Br Omar Edited October 18, 2020 by Omar_one Get the latest Responsive osCommerce CE (community edition) here . Share this post Link to post Share on other sites
♥ecartz 724 Posted October 18, 2020 if ((empty($_GET['s2p_id']) || ($_GET['s2p_id'] == $s2p['s2p_id'])) && (empty($trInfo)) && (!isset($_GET['action']) || (substr($_GET['action'], 0, 3) != 'new'))) { Always back up before making changes. Share this post Link to post Share on other sites
Omar_one 154 Posted October 18, 2020 7 minutes ago, ecartz said: if ((empty($_GET['s2p_id']) || ($_GET['s2p_id'] == $s2p['s2p_id'])) && (empty($trInfo)) && (!isset($_GET['action']) || (substr($_GET['action'], 0, 3) != 'new'))) { Thank you @ecartz that fix if but now I get 2 another error Notice: Undefined variable: trInfo in C:\xampp\htdocs\test\admin\ship2pay.php on line 112 line 103-117 <?php $s2p_query_raw = "select s2p_id, shipment, payments_allowed, status from ship2pay"; $s2p_split = new splitPageResults($_GET['page'], MAX_DISPLAY_SEARCH_RESULTS, $s2p_query_raw, $s2p_query_numrows); $s2p_query = tep_db_query($s2p_query_raw); while ($s2p = tep_db_fetch_array($s2p_query)) { if ((empty($_GET['s2p_id']) || ($_GET['s2p_id'] == $s2p['s2p_id'])) && (empty($trInfo)) && (!isset($_GET['action']) || (substr($_GET['action'], 0, 3) != 'new'))) { $trInfo = new objectInfo($s2p); } if ( (is_object($trInfo)) && ($s2p['s2p_id'] == $trInfo->s2p_id) ) { echo ' <tr class="dataTableRowSelected" onmouseover="this.style.cursor=\'hand\'" onclick="document.location.href=\'' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $trInfo->s2p_id . '&action=edit') . '\'">' . "\n"; } else { echo ' <tr class="dataTableRow" onmouseover="this.className=\'dataTableRowOver\';this.style.cursor=\'hand\'" onmouseout="this.className=\'dataTableRow\'" onclick="document.location.href=\'' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $s2p['s2p_id']) . '\'">' . "\n"; } ?> and Notice: Undefined variable: trInfo in C:\xampp\htdocs\test\admin\ship2pay.php on line 128 and here the lines 121-129 <?php if ($s2p['status'] == '1') { echo tep_image('images/icon_status_green.gif', IMAGE_ICON_STATUS_GREEN, 10, 10) . ' <a href="' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $s2p['s2p_id'] . '&action=disable') . '">' . tep_image('images/icon_status_red_light.gif', IMAGE_ICON_STATUS_RED_LIGHT, 10, 10) . '</a>'; } else { echo '<a href="' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $s2p['s2p_id'] . '&action=enable') . '">' . tep_image('images/icon_status_green_light.gif', IMAGE_ICON_STATUS_GREEN_LIGHT, 10, 10) . '</a> ' . tep_image('images/icon_status_red.gif', IMAGE_ICON_STATUS_RED, 10, 10); } ?></td> <td class="dataTableContent" align="right"><?php if ( (is_object($trInfo)) && ($s2p['s2p_id'] == $trInfo->s2p_id) ) { echo tep_image('images/icon_arrow_right.gif', ''); } else { echo '<a href="' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $s2p['s2p_id']) . '">' . tep_image('images/icon_info.gif', IMAGE_ICON_INFO) . '</a>'; } ?> </td> </tr> Get the latest Responsive osCommerce CE (community edition) here . Share this post Link to post Share on other sites
♥ecartz 724 Posted October 19, 2020 if ( isset($trInfo->s2p_id) && ($s2p['s2p_id'] == $trInfo->s2p_id) ) { echo ' <tr class="dataTableRowSelected" onmouseover="this.style.cursor=\'hand\'" onclick="document.location.href=\'' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $trInfo->s2p_id . '&action=edit') . '\'">' . "\n"; $icon = tep_image('images/icon_arrow_right.gif', ''); } else { echo ' <tr class="dataTableRow" onmouseover="this.className=\'dataTableRowOver\';this.style.cursor=\'hand\'" onmouseout="this.className=\'dataTableRow\'" onclick="document.location.href=\'' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $s2p['s2p_id']) . '\'">' . "\n"; $icon = '<a href="' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $s2p['s2p_id']) . '">' . tep_image('images/icon_info.gif', IMAGE_ICON_INFO) . '</a>'; } That's replacing 112-116. Then at 128 <td class="dataTableContent" align="right"><?= $icon ?> </td> Always back up before making changes. Share this post Link to post Share on other sites
♥BrockleyJohn 312 Posted October 19, 2020 On 10/17/2020 at 9:18 PM, Omar_one said: @BrockleyJohn is there any plan to update it to Phoenix? Plan would be putting it over strongly - I have been thinking it could do with revisiting now for all the changes in checkout. It could probably do with a redesign now that there are hooks all over the place - and maybe for the newly abstracted shipping & payment modules. And of course a bootstrapped admin page. seems like you've got an interim solution though Contact me for work on updating existing stores - whether to Phoenix or the new osC when it's released. Looking for a payment or shipping module? Maybe I've already done it. Working on generalising bespoke solutions for Quickbooks integration, Easify integration and pay4later (DEKO) integration at 2.3.x Share this post Link to post Share on other sites
Omar_one 154 Posted October 19, 2020 16 hours ago, ecartz said: if ( isset($trInfo->s2p_id) && ($s2p['s2p_id'] == $trInfo->s2p_id) ) { echo ' <tr class="dataTableRowSelected" onmouseover="this.style.cursor=\'hand\'" onclick="document.location.href=\'' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $trInfo->s2p_id . '&action=edit') . '\'">' . "\n"; $icon = tep_image('images/icon_arrow_right.gif', ''); } else { echo ' <tr class="dataTableRow" onmouseover="this.className=\'dataTableRowOver\';this.style.cursor=\'hand\'" onmouseout="this.className=\'dataTableRow\'" onclick="document.location.href=\'' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $s2p['s2p_id']) . '\'">' . "\n"; $icon = '<a href="' . tep_href_link('ship2pay.php', 'page=' . $_GET['page'] . '&s2p_id=' . $s2p['s2p_id']) . '">' . tep_image('images/icon_info.gif', IMAGE_ICON_INFO) . '</a>'; } That's replacing 112-116. Then at 128 <td class="dataTableContent" align="right"><?= $icon ?> </td> thank you @ecartz 👍 Get the latest Responsive osCommerce CE (community edition) here . Share this post Link to post Share on other sites
Omar_one 154 Posted October 19, 2020 10 hours ago, BrockleyJohn said: Plan would be putting it over strongly - I have been thinking it could do with revisiting now for all the changes in checkout. It could probably do with a redesign now that there are hooks all over the place - and maybe for the newly abstracted shipping & payment modules. its will be good if it will be a hooks . 10 hours ago, BrockleyJohn said: And of course a bootstrapped admin page. its work well now .. one issue .. that I can't delete the records as you see there is not delete button.. I will check it again ..I don't think its that important just delete the the records via phpmyadmin Get the latest Responsive osCommerce CE (community edition) here . Share this post Link to post Share on other sites
driven22 1 Posted September 20, 2021 (edited) Hi, i have same problem with shi2pay. Can you help mi (last version Phoenix) ? Quote Notice: Undefined index: action in /xxxxx/admin/ship2pay.php on line 44 if ($_GET['action']) { switch ($_GET['action']) { Quote Notice: Undefined index: action in /home/xxxxx/admin/ship2pay.php on line 153Notice: Undefined variable: trInfo in /home/xxxxx/admin/ship2pay.php on line 178 switch ($_GET['action']) { if (is_object($trInfo)) { I have a lot problems with ship2pay. In Phoenix version removed class/payment.php . Edited September 20, 2021 by driven22 changes Share this post Link to post Share on other sites