MountainMan Posted April 18, 2022 Posted April 18, 2022 (edited) Error message is not displaying in checkout_payment. Am looking for tips in how to diagnose. This bit of error handling code has been around a long time. In OSC 2.3.4.1, it starts at line #130 in checkout_payment.php if (isset($HTTP_GET_VARS['payment_error']) && is_object(${$HTTP_GET_VARS['payment_error']}) && ($error = ${$HTTP_GET_VARS['payment_error']}->get_error())) { First question I have, is: Why is there a single "=" instead of a "==" for the "$error = $" in the line above Second question is: Where does "$error['title']" come from? I am assuming it is an array element...but where created and loaded with data. I know these error messages come from payment or order total modules, but I cannot find any code referencing "title". echo '<strong>' . tep_output_string_protected($error['title']) Third question: Why is OSC 2.3.4.1 still using $HTTP_GET_VARS ? Thought we were past that. Edited April 18, 2022 by MountainMan Further clarification Quote
MountainMan Posted April 18, 2022 Author Posted April 18, 2022 Answering my own questions: 1. The single "=" is required because there is in fact an assignment to the variable $error going on there 2. $error['title'] is assigned in the get_error() functions found in the order total modules 3. Above my pay grade The reason the error messages were not showing up was because I left off a "return" in the get_error() function I was repurposing. Quote
Jack_mcs Posted April 19, 2022 Posted April 19, 2022 21 hours ago, MountainMan said: Third question: Why is OSC 2.3.4.1 still using $HTTP_GET_VARS ? Thought we were past that. That version of oscommerce hasn't been updated in about 5 years. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons
MountainMan Posted April 19, 2022 Author Posted April 19, 2022 53 minutes ago, Jack_mcs said: That version of oscommerce hasn't been updated in about 5 years. Thanks. Which version(s) are the latest and greatest has gotten confusing. Can you school me on that? Quote
Jack_mcs Posted April 19, 2022 Posted April 19, 2022 @MountainManPlease see the PM I sent. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons
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.