Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Demitry

Members
  • Posts

    535
  • Joined

  • Last visited

  • Days Won

    26

Everything posted by Demitry

  1. ok, all fixed. I changed that function above to this and no more errors. function SelectDB(){ return mysqli_select_db($this->link_id, $this->db); } # end function
  2. @Jack_mcs ok, update, ..I actually got them all to generate. I just have to clear this php warning: Warning: mysqli_select_db() expects exactly 2 parameters, 1 given in /home/ ... /public_html/dev2/googlesitemap/sitemap.class.php on line 97 and here is the function this warning is referring to: function SelectDB(){ return mysqli_select_db($this->db); } # end function
  3. I'm looking at it from the webpage, and on the older version this page had links to all the other xml sitemaps. And all the other xml pages had links to the individual pages listed,.. though this was not in xml format. This latest addon version is different in that it lists each of the pages in xml format but without links to anything. Is this how it is supposed to be? Here is the output I got when running that .../googlesitemap/index.php file. Let me know if anything sticks out that I may be able to change to get this working right. ERROR: Google Product Sitemap Generation FAILED! ERROR: Google Category Sitemap Generation FAILED! ERROR: Google Images Sitemap Generation FAILED! ERROR: Google Manufacturers Sitemap Generation FAILED! Opening /home/ ... /public_html/dev2/sitemappages.xml FS_CAT /home/ ... /public_html/dev2/ Server http://dev2.MyDomain.com Save Path /home/ ... /public_html/dev2/ WS_CAT / Write /home/ ... /public_html/dev2/sitemappages.xml Generated Google Pages Sitemap Successfully ERROR: Google Specials Sitemap Generation FAILED! Opening /home/ ... /public_html/dev2/sitemapindex.xml FS_CAT /home/ ... /public_html/dev2/ Server http://dev2.MyDomain.com Save Path /home/ ... /public_html/dev2/ WS_CAT / Write /home/ ... /public_html/dev2/sitemapindex.xml Generated Google Sitemap Index Successfully Array ( [QUERY] => Array ( [PRODUCTS] => Array ( [STATUS] => false [NUM_ROWS] => 0 ) [CATEOGRY] => Array ( [STATUS] => false [NUM_ROWS] => 0 ) [IMAGES] => Array ( [STATUS] => false [NUM_ROWS] => 0 ) [MANUFACTURERS] => Array ( [STATUS] => false [NUM_ROWS] => 0 ) [SPECIALS] => Array ( [STATUS] => false [NUM_ROWS] => 0 ) ) [SAVE_FILE_XML] => Array ( [0] => Array ( [file] => /home/ ... /public_html/dev2/sitemappages.xml [status] => success [file_exists] => true ) [1] => Array ( [file] => /home/ ... /public_html/dev2/sitemapindex.xml [status] => success [file_exists] => true ) ) )
  4. Well, that did work partially. I can now view the diagnostic output and two of the sitemap files got filled in - the sitemappages.xml and the sitemapindex.xml However sitemapindex.xml does not have links to the other sitemap xml pages, it just came out like an xml page of its own. That's not how the older version I have works, so I'm not sure if this is an error or an intended change. I did add an older modification which seems to work well,.. It eliminates all pages that are disallowed in the robots.txt file. That prevents having to enter them twice, once into the robots.txt file, and again into the admin panel configuration page for this addon. Anyway, I have a few more things to test and see if I can get this addon to work.
  5. ok Jack, @Jack_mcs Thank you for the suggestion. I'll give it a try. I did not read through all the pages of this forum so I did not know about issues with PHP7. I'll let you know what I come up with. Thanks.
  6. ok, a bit of progress in my situation. I enabled errors in the index.php file and got this, which means there is some database connectivity issue with the ConnectDB() function. Fatal error: Uncaught Error: Call to undefined function mysql_connect() in /home/ ... /public_html/dev2/googlesitemap/sitemap.class.php:83 I'm still not sure how to fix this...
  7. hi Jack, @Jack_mcs I installed this contribution on a subdomain with osC v2.3.4 BS Edge, PHP7.1.7 I set in the configuration to allow for the various sitemap generation, took out the days time limit on manual regeneration, added my ip for Manual IP and Secure IP, ..and enabled the Diagnostic Output. However, I get nothing, just a blank page when I go to ..../googlesitemap/index.php There is nothing in my error log either. Any thoughts? This is the only error I get on the actual sitemap page. See image below.
  8. @Dan Cole Dan, thank you for the reply. I apologize, I missed it in that module. I thought I went through all of the modules thoroughly, but apparently not.
  9. @raiwa yep, you're right,.. I checked it myself last night after asking here. When comparing the module files and the shopping_cart.php file, I did notice that the following code was removed, and I could not locate it in any of the new module files. Is it not necessary for the shopping_cart.php file? if ($cart->count_contents() > 0) { include('includes/classes/payment.php'); $payment_modules = new payment; }
  10. @raiwa hey Rainer, I have not installed this addon yet, and wanted to know if it will work with the PWA addon? This one: https://apps.oscommerce.com/5f3nn&purchase-without-account-bs I assume it will, but have to ask. Thanks.
  11. @kymation I am working on finishing a new MVS BS Edge release with several new features and it fixes a problem with Free Shipping, ..including allowing a customer to have the option for expedited shipping after they have reached the minimum amount required for free shipping. After I finish this update, you should set it up on BS EDGE and PHP7.1 ..It's niiiiiiiice!
  12. yeah, and I tested it, Even if you select one of the shipping methods for one of the vendors, but not the other, the checkout_shipping.php page will not let you move on to the checkout_payment.php page and all the radio buttons light up like Christmas lights. Try it yourself, ..you'll see. That test may have been of use in an older osC version, but BS Edge has it built into the checkout_shipping.php page. And realistically this would never be needed at all if that issue I mentioned above regarding the radio buttons being un-selected when returning to the checkout_shipping.php page,.. was resolved.
  13. @kymation I think I found a way to fix this ...just comment out that if statement on checkout_payment.php and on checkout_confirmation.php pages. It's there as a test to make sure that a shipping method for each vendor is selected. However, in BS Edge it is not needed because a customer cannot proceed to the payment page without having those shipping method radio buttons selected.
  14. @kymation so which free shipping option should I be using, if not the one that is included with MVS?
  15. @kymation I'm having an issue with Free Shipping and was wondering if you have come across this issue before. When proceeding to the checkout_payment page from checkout_shipping after reaching the Free shipping minimum, I am redirected back to the checkout_shipping page via this line: if (!is_array($shipping['vendor']) || count($shipping['vendor']) != count($cart->vendor_shipping)) { After doing a var_dump I found that count($shipping['vendor']) is coming back with 0 for free shipping, while count($cart->vendor_shipping) is coming back with 2,.. as in the two vendors I am testing. Also,.. var_dump(($shipping['vendor'])); is coming back as NULL. So, when the minimum amount for Free shipping is reached, the shipping vendors are not counted. I think this is on the checkout_shipping.php page for the MVS code or perhaps in the freeamount.php module. Could you help on this?
  16. @kymation Actually, it’s not rare at all, but rather consistent. As in, when you get to the confirmation page and click on the Edit button to edit the shipping options, you can be sure of one thing, ..none of the shipping methods you selected or where auto-selected for you (as the cheapest option) ..will be selected. I think the shipping method selections need to be somehow added to the session. I’m not exactly sure how to structure that.
  17. @kymation Hey Jim, I noticed something that I'd like to fix. When checking out, the MVS system works as it should and selects the radio button for the cheapest shipping method for each vendor. However, after proceeding and then going back to that checkout_shipping.php page, no shipping methods are selected for any of the vendors. Any way to resolve this? Thanks.
  18. MVS for v2.3.4 BS EDGE is now available! Please note that this is for BS Edge ONLY https://apps.oscommerce.com/Apps&lsS4c&mvs-for-v2-3-4-bs-edge
  19. @BrockleyJohn For that var_dump of $vendor_shipping right before the line you mentioned I get the following: array(2) { [1]=> array(6) { ["weight"]=> float(7) ["cost"]=> float(35.99) ["qty"]=> int(1) ["ship_cost"]=> float(0) ["products_id"]=> array(1) { [0]=> int(8) } ["products_qty"]=> array(1) { [8]=> string(1) "1" } } [2]=> array(6) { ["weight"]=> float(7) ["cost"]=> float(39.99) ["qty"]=> int(1) ["ship_cost"]=> float(0) ["products_id"]=> array(1) { [0]=> int(17) } ["products_qty"]=> array(1) { [17]=> string(1) "1" } } } And I forgot to include Flat Rate as one of the shipping options I have for the current testing scenario. Here is a screenshot of the shipping options as I have them. USPS in the first vendor's product is not the cheapest method, but I selected it to display related testing data. The other modules really do nothing in relation to this sessions issue. I could just as well remove them all and just have USPS for both vendor products.
  20. @BrockleyJohn That line was added for MVS v1.3 (latest though not for BS Edge) by @drillsar here is the link to it. And @kymation Jim says that it's necessary just below that first post. Here is the same line in my MVS install for an older version of osC (MS2.2) and one that does not have this sessions issue. However, that site is running on PHP5.3 $shipping = array('id' => $shipping, I've tested this line by switching to the one without the session variable, but it made no difference. I have the following modules enabled (USPS, FedEx Web Services, Table, UPS ), however, none of the other ones cause a problem with the session. I had remove them all and added them one by one while testing the checkout with each add. The one that caused the issue is the USPS module. If I disable it or remove it, I can get to the checkout_payment.php page. With it enabled I get the login.php page. I appreciate your help John.
  21. @BrockleyJohn thanks, I checked that language file and other than a url link for one of the definitions and <br /> instead of a <br> there are no special characters that would trigger this session kill. There is a USPS module in the MVS addon, so it is supposed to work with it. However, I used the one form this contribution, which is a more detailed and better module. This addon also has a version specifically for the MVS module and that is the one I am working with. I'll keep testing for the session break to see what code in this USPS module with require adjustment.
  22. @BrockleyJohn John, it's actually a bit higher in the code because I am using the MVS addon. So, what I did was to comment out the redirect to the payment page and pulled the session content right before the redirect to the payment page in checkout_shipping.php By the point that this redirect is reached on that page, the session has already been destroyed. That's why as soon as the checkout_payment.php page loads, the first redirect is to the login page. // process the selected shipping method if ( isset($_POST['action']) && ($_POST['action'] == 'process') && isset($_POST['formid']) && ($_POST['formid'] == $sessiontoken) ) { if (!tep_session_is_registered('comments')) tep_session_register('comments'); if (tep_not_null($_POST['comments'])) { $comments = tep_db_prepare_input($_POST['comments']); } if (!tep_session_is_registered('shipping')) tep_session_register('shipping'); // MVS start if (SELECT_VENDOR_SHIPPING == 'true') { $total_shipping_cost = 0; $shipping_title = MULTIPLE_SHIP_METHODS_TITLE; $vendor_shipping = $cart->vendor_shipping; $shipping = array(); foreach ($vendor_shipping as $vendor_id => $vendor_data) { $products_shipped = $_POST['products_' . $vendor_id]; $products_array = explode ("_", $products_shipped); $shipping_data = $_POST['shipping_' . $vendor_id]; $shipping_array = explode ("_", $shipping_data); $module = $shipping_array[0]; $method = $shipping_array[1]; $ship_tax = $shipping_array[2]; if ( is_object($$module) || ($module == 'free') ) { if ($module == 'free') { $quote[0]['methods'][0]['title'] = FREE_SHIPPING_TITLE; $quote[0]['methods'][0]['cost'] = '0'; } else { $total_weight = $vendor_shipping[$vendor_id]['weight']; $shipping_weight = $total_weight; $cost = $vendor_shipping[$vendor_id]['cost']; $total_count = $vendor_shipping[$vendor_id]['qty']; $quote = $shipping_modules->quote($method, $module, $vendor_id); } if (isset($quote['error'])) { tep_session_unregister('shipping'); } else { if ( (isset($quote[0]['methods'][0]['title'])) && (isset($quote[0]['methods'][0]['cost'])) ) { $output[$vendor_id] = array('id' => $module . '_' . $method, 'title' => $quote[0]['methods'][0]['title'], 'ship_tax' => $ship_tax, 'products' => $products_array, 'cost' => $quote[0]['methods'][0]['cost'] ); $total_ship_tax += $ship_tax; $total_shipping_cost += $quote[0]['methods'][0]['cost']; }//if isset }//if isset }//if is_object }//foreach if ($free_shipping == true) { $shipping_title = $quote[0]['module']; } elseif (count($output) < 2) { $shipping_title = $quote[0]['methods'][0]['title']; } //MVS $shipping = array('id' => $_SESSION['shipping'], 'title' => $shipping_title, 'cost' => $total_shipping_cost, 'shipping_tax_total' => $total_ship_tax, 'vendor' => $output ); print '<pre>'; var_dump($_SESSION); die; //tep_redirect(tep_href_link('checkout_payment.php', '', 'SSL')); } else { // MVS if (SELECT_VENDOR_SHIPPING == 'true') // MVS end if ( (tep_count_shipping_modules() > 0) || ($free_shipping == true) ) { if ( (isset($_POST['shipping'])) && (strpos($_POST['shipping'], '_')) ) { $shipping = $_POST['shipping']; list($module, $method) = explode('_', $shipping); if ( is_object($$module) || ($shipping == 'free_free') ) { if ($shipping == 'free_free') { $quote[0]['methods'][0]['title'] = FREE_SHIPPING_TITLE; $quote[0]['methods'][0]['cost'] = '0'; } else { $quote = $shipping_modules->quote($method, $module); } if (isset($quote['error'])) { tep_session_unregister('shipping'); } else { if ( (isset($quote[0]['methods'][0]['title'])) && (isset($quote[0]['methods'][0]['cost'])) ) { $shipping = array('id' => $shipping, 'title' => (($free_shipping == true) ? $quote[0]['methods'][0]['title'] : $quote[0]['module'] . ' (' . $quote[0]['methods'][0]['title'] . ')'), 'cost' => $quote[0]['methods'][0]['cost']); tep_redirect(tep_href_link('checkout_payment.php', '', 'SSL')); } } } else { tep_session_unregister('shipping'); } } } else { if ( defined('SHIPPING_ALLOW_UNDEFINED_ZONES') && (SHIPPING_ALLOW_UNDEFINED_ZONES == 'False') ) { tep_session_unregister('shipping'); } else { $shipping = false; tep_redirect(tep_href_link('checkout_payment.php', '', 'SSL')); } } // if ( (tep_count_shipping_modules() > 0) } // MVS if (SELECT_VENDOR_SHIPPING == 'true') } // if ( isset($_POST['action']) && However, what I think I should be doing is testing the session output in the actual USPS module file. Am I right on that? Regarding the language file and replacing it. I assume you mean the /admin/language.php file, but replace it with what? My BS Edge version is from last August. I'm not sure if there is a more updated version out or if that file was updated since the release I have installed. Is that what you meant?
  23. @kymation Jim, that did work and I am able to view the session output,.. but I am not sure what I'm looking for in this output, or how it will pin point where the code issue is in the usps.php module file.
  24. @kymation Jim, It's not the constructor issue. That was the only thing I changed in that file. The constructor error would have come up as an on-page PHP error, and not the logged session destroyed error written to the error log file. @BrockleyJohn John, I was thinking something similar,.. perhaps along the lines of conflicts with unicode utf8, however, I am not sure of how to test the session, especially when dealing with a back-end process. Try echoing out what it's putting in the session and exiting before the redirect to checkout_payment. I apologize in advance as this is likely a simple and common way of testing, but I've never done it and am not sure how to do that. Could you tell me the steps to do this? I've never looked at the contents of a session and am not sure how I can. What I've done was to determine where the session is being killed and that was at the following line in checkout_shipping.php Both the $sessiontoken and tep_session_is_registered('customer_id') came up empty after this line. if ( isset($_POST['action']) && ($_POST['action'] == 'process') && isset($_POST['formid']) && ($_POST['formid'] == $sessiontoken) ) { So, after that I started checking the installed modules one-by-one and that's how I discovered that the USPS module was causing the session issue. However, I'm now a bit stuck because I am not sure how to further test to identify the issue in this module.
  25. @kymation Jim, I've narrowed down that MVS sessions issue to the USPS module from this addon. I used the MVS version from this addon. When installed and I try to proceed to the checkout_payment.php page, the session ends and I get redirected to the login page. The checkout_shipping.php page looks fine, it is just when I try to continue to the payment page is when the session ends. The exact error is: [05-Mar-2018 23:49:27 America/New_York] PHP Warning: session_start(): Failed to decode session object. Session has been destroyed in /home/xxxxxx/public_html/dev2/includes/functions/sessions.php on line 110 When I disable or uninstall that USPS module, the problem goes away. Could you try and test it on your end to see if this is in fact a bug? I have this set up on BS Edge with PHP7.1.7 Thanks.
×
×
  • Create New...