mhsuffolk Posted September 14, 2019 Share Posted September 14, 2019 (edited) I have installed 1.0.6 Still cannot save cards in test mode. Not tried live. Stripe dashboard error says { "error": { "code": "resource_missing", "doc_url": "https://stripe.com/docs/error-codes/resource-missing", "message": "No such customer: cus_************; a similar object exists in live mode, but a test mode key was used to make this request.", "param": "customer", "type": "invalid_request_error" Cannot access saved cards in live that were saved by the old module. Token exists in the database, with the same customer hash as the blanked out one above. When I click the saved Cards link on the account page the screen just flicks and comes back to where it was. Edited September 14, 2019 by mhsuffolk Quote Live shop Phoenix 1.0.8.4 on PHP 7.4 Working my way up the versions. Link to comment Share on other sites More sharing options...
peterespana Posted September 14, 2019 Share Posted September 14, 2019 7 hours ago, peterespana said: This is the log that appears:  ID req_LWmdlGmOiCG4W6 Time 9/14/19, 7:01:22 AM Method POST URL /v1/payment_intents/pi_1FITLjK4kydItoIjO Status 200 IP address 81.169.144.135 Version 2018-05-21 Source Stripe/v1 PhpBindings/6.43.0 Related payment_intent   Thanks!! Peter Removed the module and installed 1.06. But still the same error: IntegrationError: Invalid value for stripe.handleCardPayment intent secret: value should be a client_secret string. You specified: undefined. Thanks. Log files says: ID req_MhL0nXN5BhCHOB Time 9/14/19, 2:10:44 PM Method POST URL /v1/payment_intents Status 200 IP address 81.169.144.135 Version 2018-05-21 Source Stripe/v1 PhpBindings/6.43.0 Related payment_intent — pi_1FIa5 Quote Link to comment Share on other sites More sharing options...
mhsuffolk Posted September 14, 2019 Share Posted September 14, 2019 Update, I can now save cards and use them in test mode. I did not change anything apart from creating a new customer. it appears to have healed itself. However I still cannot access the saved cards page in test or live. Quote Live shop Phoenix 1.0.8.4 on PHP 7.4 Working my way up the versions. Link to comment Share on other sites More sharing options...
asro2004 Posted September 15, 2019 Author Share Posted September 15, 2019 15 hours ago, 14steve14 said: Link to latest release version Latest version Is it a case that all the files in this latest release need to re-uploaded to the site or is it just the odd one or two. Upgrade instruction would be nice.   It's probably easiest to just overwrite all of them. Quote Link to comment Share on other sites More sharing options...
asro2004 Posted September 16, 2019 Author Share Posted September 16, 2019 @peterespanaWere you able to see the stripe_event_log mysql table in your store database? It should create a row with the 'action' 'page create intent', and a request something like: {"amount":"7500","currency":"USD","setup_future_usage":"off_session","capture_method":"automatic","metadata":{"customer_id":"26","order_id":"2640","company":"","product_1_name":"Grillage for 6 beam 3 span bridge","product_1_model":"","product_1_id":"72{6}14","product_1_qty":"1","product_1_price":"75.0000","product_1_tax":0}} and the response should be the payment intent object returned by stripe, or an error message. You should see a line in the response 'client_secret', and it is that value that is placed in a hidden field in the payment form by the code in the confirmation function of stripe_sca.php. With the error message you are getting, would suggest an error response from Stripe when the intent is created, but your Stripe log shows a response code 200. Try looking in your PHP error log, or Apache/Nginx log, or check the browser console for any javascript error. Have a look at the page source of the checkout_payment.php page, and search for id="secret". The value of that field should be the client secret returned by Stripe in the payment intent object. Quote Link to comment Share on other sites More sharing options...
asro2004 Posted September 16, 2019 Author Share Posted September 16, 2019 On 9/15/2019 at 12:23 AM, mhsuffolk said: Update, I can now save cards and use them in test mode. I did not change anything apart from creating a new customer. it appears to have healed itself. However I still cannot access the saved cards page in test or live. Is that the 'Manage save cards' in the my account page? Please check your PHP or Apache/Nginx web site log for any errors. The account page is loading the code from includes/modules/content/account/cm_account_stripe_sca_cards.php, with the English text from includes/languages/english/modules/content/account/cm_account_stripe_sca_cards.php Quote Link to comment Share on other sites More sharing options...
mhsuffolk Posted September 16, 2019 Share Posted September 16, 2019 33 minutes ago, asro2004 said: The account page is loading the code from includes/modules/content/account/cm_account_stripe_sca_cards.php Yes, it is the manage saved cards page. No errors in my PHP logs. I don't know if I should be able to, but if I call includes/modules/content/account/cm_account_stripe_sca_cards.php it returns a 403 error. I notice that the hyperlink on the accounts.php page is returning ext/modules/content/account/stripe_sca/cards.php Is this correct? Quote Live shop Phoenix 1.0.8.4 on PHP 7.4 Working my way up the versions. Link to comment Share on other sites More sharing options...
peterespana Posted September 16, 2019 Share Posted September 16, 2019 6 hours ago, asro2004 said: @peterespanaWere you able to see the stripe_event_log mysql table in your store database? It should create a row with the 'action' 'page create intent', and a request something like: {"amount":"7500","currency":"USD","setup_future_usage":"off_session","capture_method":"automatic","metadata":{"customer_id":"26","order_id":"2640","company":"","product_1_name":"Grillage for 6 beam 3 span bridge","product_1_model":"","product_1_id":"72{6}14","product_1_qty":"1","product_1_price":"75.0000","product_1_tax":0}} and the response should be the payment intent object returned by stripe, or an error message. You should see a line in the response 'client_secret', and it is that value that is placed in a hidden field in the payment form by the code in the confirmation function of stripe_sca.php. With the error message you are getting, would suggest an error response from Stripe when the intent is created, but your Stripe log shows a response code 200. Try looking in your PHP error log, or Apache/Nginx log, or check the browser console for any javascript error. Have a look at the page source of the checkout_payment.php page, and search for id="secret". The value of that field should be the client secret returned by Stripe in the payment intent object. Hi, again thanks for your patience with me... Stripe return the values in the response body. That looks all normal. I checked the id-secret in the page, it's there. But the error persists (IntegrationError: Invalid value for stripe.handleCardPayment intent secret: value should be a client_secret string. You specified: undefined.) No script errors, nothing in the apache logs. Any more ideas? Regards Peter Quote Link to comment Share on other sites More sharing options...
peterespana Posted September 16, 2019 Share Posted September 16, 2019 I also get that same error when I don't fill in any creditcard number at all. When IÂ press confirm order. The order does appear in my order history admin area as Preparing [Stripe SCA] Quote Link to comment Share on other sites More sharing options...
mhsuffolk Posted September 16, 2019 Share Posted September 16, 2019 (edited) 25 minutes ago, peterespana said: The order does appear in my order history admin area as Preparing [Stripe SCA] When you get to the checkout_confirmation page, before you have even entered a card number, you should have Preparing [Stripe SCA] in your admin and in the Stripe Dashboard under Developers/logs you should have a log entry like this. What do you get? Click on the row and you should have this. Edited September 16, 2019 by mhsuffolk Quote Live shop Phoenix 1.0.8.4 on PHP 7.4 Working my way up the versions. Link to comment Share on other sites More sharing options...
mhsuffolk Posted September 16, 2019 Share Posted September 16, 2019 (edited) On 9/14/2019 at 1:23 PM, mhsuffolk said: However I still cannot access the saved cards page in test or live. Found it @asro2004 In ext/modules/content/account/stripe_sca/cards.php Line 21 if ( defined('MODULE_PAYMENT_INSTALLED') && tep_not_null(MODULE_PAYMENT_INSTALLED) && in_array('stripe.php', explode(';', MODULE_PAYMENT_INSTALLED)) ) { Change to if ( defined('MODULE_PAYMENT_INSTALLED') && tep_not_null(MODULE_PAYMENT_INSTALLED) && in_array('stripe_sca.php', explode(';', MODULE_PAYMENT_INSTALLED)) ) { This fault appeared after I had uninstalled the old Stripe module, previously it must have been using the old module's configuration values. Edited September 16, 2019 by mhsuffolk Quote Live shop Phoenix 1.0.8.4 on PHP 7.4 Working my way up the versions. Link to comment Share on other sites More sharing options...
241 Posted September 16, 2019 Share Posted September 16, 2019 @mhsuffolk @asro2004 there are a couple more stripe references that should be changed to stripe_sca in the ext/modules/content/account/stripe_sca/cards.php lines 59 and 63 redirect and breadcrumb  Quote No longer giving free advice. Please place deposit in meter slot provided. Individual: [=] SME: [==] Corporation: [===] If deposit does not fit one of the slots provided then you are asking too much! Is your Osc dated try Phoenix  raising oscommerce from the ashes. Link to comment Share on other sites More sharing options...
asro2004 Posted September 17, 2019 Author Share Posted September 17, 2019 15 hours ago, peterespana said: I also get that same error when I don't fill in any creditcard number at all. When IÂ press confirm order. The order does appear in my order history admin area as Preparing [Stripe SCA] I'm pretty sure the problem is something in the checkout_confirmation.php form. Raiwa had provided some refactoring to the handling of order processing, moving it from the webhook to the payment module, so I took the opportunity to re-check the javascript in the checkout-confirmation.php page, and removed some redundant fields and a dependency on a specific class name on the button. It was possible that a custom theme may disrupt the completion of the payment process, so this could fix it if that was the case for you. I reset the configuration and re-installed the module from scratch on a standard system, and then re-run tests for new cards, saving a new card, and using a saved card, and all worked ok. Please download and install the latest version 1.0.7 from the market place. All files should be replaced. If still no luck, please PM me a copy of the page source of checkout_confirmation.php page. Quote Link to comment Share on other sites More sharing options...
asro2004 Posted September 17, 2019 Author Share Posted September 17, 2019 13 hours ago, 241 said: @mhsuffolk @asro2004 there are a couple more stripe references that should be changed to stripe_sca in the ext/modules/content/account/stripe_sca/cards.php lines 59 and 63 redirect and breadcrumb  Thanks, they have been fixed in 1.0.7 Mikepo 1 Quote Link to comment Share on other sites More sharing options...
peterespana Posted September 17, 2019 Share Posted September 17, 2019 (edited) On 9/16/2019 at 2:28 PM, mhsuffolk said: When you get to the checkout_confirmation page, before you have even entered a card number, you should have Preparing [Stripe SCA] in your admin and in the Stripe Dashboard under Developers/logs you should have a log entry like this. What do you get? Click on the row and you should have this. Order is visible in admin (preparing Stripe SCA). This is the stripe log:   Sometimes (not always) I have that with a PayPal payment as well, an order (pending payment) is made. Payment comes in, but no order confirmation and stock remains unchanged. Like there was no order. But payment is done. Do you know what file may cause this? I guess it has to do with the same issue here.  Thanks a lot! Regards Peter  Edited September 17, 2019 by peterespana Quote Link to comment Share on other sites More sharing options...
peterespana Posted September 17, 2019 Share Posted September 17, 2019 (edited) On 9/16/2019 at 7:17 AM, asro2004 said: @peterespanaWere you able to see the stripe_event_log mysql table in your store database? It should create a row with the 'action' 'page create intent', and a request something like: {"amount":"7500","currency":"USD","setup_future_usage":"off_session","capture_method":"automatic","metadata":{"customer_id":"26","order_id":"2640","company":"","product_1_name":"Grillage for 6 beam 3 span bridge","product_1_model":"","product_1_id":"72{6}14","product_1_qty":"1","product_1_price":"75.0000","product_1_tax":0}} and the response should be the payment intent object returned by stripe, or an error message. You should see a line in the response 'client_secret', and it is that value that is placed in a hidden field in the payment form by the code in the confirmation function of stripe_sca.php. With the error message you are getting, would suggest an error response from Stripe when the intent is created, but your Stripe log shows a response code 200. Try looking in your PHP error log, or Apache/Nginx log, or check the browser console for any javascript error. Have a look at the page source of the checkout_payment.php page, and search for id="secret". The value of that field should be the client secret returned by Stripe in the payment intent object. Â Â Â Edited September 17, 2019 by peterespana Quote Link to comment Share on other sites More sharing options...
peterespana Posted September 17, 2019 Share Posted September 17, 2019 (edited) 11 hours ago, asro2004 said: I'm pretty sure the problem is something in the checkout_confirmation.php form. Raiwa had provided some refactoring to the handling of order processing, moving it from the webhook to the payment module, so I took the opportunity to re-check the javascript in the checkout-confirmation.php page, and removed some redundant fields and a dependency on a specific class name on the button. It was possible that a custom theme may disrupt the completion of the payment process, so this could fix it if that was the case for you. I reset the configuration and re-installed the module from scratch on a standard system, and then re-run tests for new cards, saving a new card, and using a saved card, and all worked ok. Please download and install the latest version 1.0.7 from the market place. All files should be replaced. If still no luck, please PM me a copy of the page source of checkout_confirmation.php page. I got a lot further now..... I could make a payment, but after entering my creditcard number it stuck, page can not be displayed.... But the payment came in. But order still is preparing, not processing. No payment info in the admin area. And no order confirmation.  This page is not working xxxxxx.com kan dit verzoek momenteel niet verwerken. HTTP ERROR 500    Any ideas where to look for this problem? The module also looks strange:   Edited September 17, 2019 by peterespana Quote Link to comment Share on other sites More sharing options...
mhsuffolk Posted September 17, 2019 Share Posted September 17, 2019 Have you installed version 1.0.7 It has had many English message labels moved to a language file, has that been missed? Quote Live shop Phoenix 1.0.8.4 on PHP 7.4 Working my way up the versions. Link to comment Share on other sites More sharing options...
peterespana Posted September 17, 2019 Share Posted September 17, 2019 5 minutes ago, mhsuffolk said: Have you installed version 1.0.7 It has had many English message labels moved to a language file, has that been missed? Yes i did install the version 1.0.7. I now checked the language file and it's there in the English folder. Quote Link to comment Share on other sites More sharing options...
mhsuffolk Posted September 17, 2019 Share Posted September 17, 2019 (edited) Your strange look picture seems to have disappeared. The file in question should be in includes/languages/english/modules/payment/stripe_sca.php I fear you have it in the wrong location as the strange look is due to missing language definitions. If it is there, has it 83 lines, the previous file was much shorter. Edited September 17, 2019 by mhsuffolk Quote Live shop Phoenix 1.0.8.4 on PHP 7.4 Working my way up the versions. Link to comment Share on other sites More sharing options...
mhsuffolk Posted September 17, 2019 Share Posted September 17, 2019 @asro2004 Updated to 1.0.7 Under 1.0.6 in the order admin I get this and confirmation emails are received Line 2 is Order processed status. Line 3 is Transaction order status. (I have changed the label text) Under 1.0.7 I get this only and no emails are received. That is the Order processed status is not reached, payments have completed correctly in Stripe dashboard. Quote Live shop Phoenix 1.0.8.4 on PHP 7.4 Working my way up the versions. Link to comment Share on other sites More sharing options...
♥raiwa Posted September 17, 2019 Share Posted September 17, 2019 29 minutes ago, mhsuffolk said: @asro2004 Updated to 1.0.7 Under 1.0.6 in the order admin I get this and confirmation emails are received Line 2 is Order processed status. Line 3 is Transaction order status. (I have changed the label text) Under 1.0.7 I get this only and no emails are received. That is the Order processed status is not reached, payments have completed correctly in Stripe dashboard. Please do not use 1.0.7 for now. The code for order_status_history and order mails is removed/wrong. I have sent a PM to the author already and I suppose he will fix it in the next update. Mikepo and mhsuffolk 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...
asro2004 Posted September 18, 2019 Author Share Posted September 18, 2019 1.0.8 has been uploaded to the market place. It fixes missing customer emails, and order status history information. If would be a good idea to copy the entire contents of the ext and includes folders in the update to the corresponding folders of the store to ensure that all files get to the right places. Â Quote Link to comment Share on other sites More sharing options...
♥raiwa Posted September 18, 2019 Share Posted September 18, 2019 1.0.8 has still problems with the order status and order comments not beeing saved. I didn't test anything on the cart save part. Here my update to v 1.0.9 which fixes it. I sent the whole updated package to Alastair to revise and upload it. Here my package for to test: stripe_sca_v1.0.9.zip  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...
peterespana Posted September 18, 2019 Share Posted September 18, 2019 (edited) Stil some issues here.... I can now make a payment with version 1.0.8 Looks like it all finishes normally. But, it stays in Stripe as uncaptured. And no payment info in the admin area:Â remains as preparing.... I use a discount code coupon module, the discount is not visible in the order. And last it ads more VAT, IÂ have 1.61157 shipping +21% VAT = 1,95. This module ads 21% to 1,95. Â Thanks for all the help, it's much appreciated. Edited September 18, 2019 by peterespana 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.