woocommerce / woocommerce-gateway-stripe Goto Github PK
View Code? Open in Web Editor NEWThe official Stripe Payment Gateway for WooCommerce
Home Page: https://wordpress.org/plugins/woocommerce-gateway-stripe/
The official Stripe Payment Gateway for WooCommerce
Home Page: https://wordpress.org/plugins/woocommerce-gateway-stripe/
=== WooCommerce Stripe Payment Gateway === Contributors: woocommerce, automattic, royho, akeda, mattyza, bor0, woothemes Tags: credit card, stripe, apple pay, payment request, google pay, sepa, bancontact, alipay, giropay, ideal, p24, woocommerce, automattic Requires at least: 6.2 Tested up to: 6.5.2 Requires PHP: 7.4 Stable tag: 8.4.0 License: GPLv3 License URI: https://www.gnu.org/licenses/gpl-3.0.html Attributions: thorsten-stripe Take credit card payments on your store using Stripe. == Description == Accept Visa, MasterCard, American Express, Discover, JCB, Diners Club, SEPA, iDEAL, giropay, Alipay, and more directly on your store with the Stripe payment gateway for WooCommerce, including Apple Pay, Google Pay, and Microsoft Pay for mobile and desktop. = Take Credit card payments easily and directly on your store = The Stripe plugin extends WooCommerce allowing you to take payments directly on your store via Stripe’s API. Stripe is available for Store Owners and Merchants in: * Australia * Austria * Belgium * Brazil * Bulgaria * Canada * Cyprus * Czech Republic * Denmark * Estonia * Finland * France * Germany * Greece * Hong Kong * Ireland * Italy * Japan * Latvia * Lithuania * Luxembourg * Malaysia * Malta * Mexico * Netherlands * New Zealand * Norway * Poland * Portugal * Puerto Rico * Singapore * Slovakia * Slovenia * Spain * Sweden * Switzerland * United Kingdom * United States * [with more being added](https://stripe.com/global) Stripe is a simple way to accept payments online. With Stripe you can accept Visa, MasterCard, American Express, Discover, JCB, and Diners Club cards, even Bitcoin, directly on your store. = Why choose Stripe? = Stripe has no setup fees, no monthly fees, no hidden costs: you only get charged when you earn money! Earnings are transferred to your bank account on a 7-day rolling basis. Stripe also supports the [WooCommerce Subscriptions extension](https://woocommerce.com/products/woocommerce-subscriptions/) and re-using cards. When a customer pays, they are set up in Stripe as a customer. If they create another order, they can check out using the same card. A massive timesaver for returning customers. = Apple Pay Support = WooCommerce Stripe includes [Apple Pay](https://woocommerce.com/apple-pay) support, which means customers can pay using payment details associated with their Apple ID. Checkout is now just an authorization (Touch ID or Face ID) away on both mobile and desktop. Only supports simple, variable, and Subscription products for now. More support to come. = Web Payments API Support = WooCommerce Stripe includes [Web Payments API](https://www.w3.org/TR/payment-request/) support, which means customers can pay using payment details associated to their mobile devices, in browsers supporting the Web Payments API (Chrome for Android, amongst others). Checkout is now just a few taps away on mobile. Only supports simple, variable, and Subscription products for now. More support to come. == Installation == You can download an [older version of this gateway for older versions of WooCommerce from here](https://wordpress.org/plugins/woocommerce-gateway-stripe/developers/). Please note, v4 of this gateway requires WooCommerce 3.0 and above. = Automatic installation = Automatic installation is the easiest option as WordPress handles the file transfers itself and you don’t need to leave your web browser. To do an automatic install of the WooCommerce Stripe plugin, log in to your WordPress dashboard, navigate to the Plugins menu and click Add New. In the search field type “WooCommerce Stripe Payment Gateway” and click Search Plugins. Once you’ve found our plugin you can view details about it such as the point release, rating, and description. Most importantly, of course, you can install it by simply clicking "Install Now", then "Activate". = Manual installation = The manual installation method involves downloading our plugin and uploading it to your web server via your favorite FTP application. The WordPress codex contains [instructions on how to do this here](http://codex.wordpress.org/Managing_Plugins#Manual_Plugin_Installation). = Updating = Automatic updates should work like a charm; as always though, ensure you backup your site just in case. == Frequently Asked Questions == = Does this support recurring payments, like for subscriptions? = Yes! = Does this require an SSL certificate? = Yes! In Live Mode, an SSL certificate must be installed on your site to use Stripe. In addition to SSL encryption, Stripe provides an extra JavaScript method to secure card data using [Stripe Elements](https://stripe.com/elements). = Does this support both production mode and sandbox mode for testing? = Yes, it does - production and Test (sandbox) mode is driven by the API keys you use with a checkbox in the admin settings to toggle between both. = Where can I find documentation? = For help setting up and configuring, please refer to our [documentation](https://woocommerce.com/document/stripe/). = Where can I get support or talk to other users? = If you get stuck, you can ask for help in the Plugin Forum. == Screenshots == 1. The Stripe payment gateway settings page used to configure the plugin. 2. Offer a range of payment options such as local methods and express checkouts. 3. Allow customers to save payment methods and add new ones for their future purchases. 4. Apple Pay and other express methods can be added to product pages, cart, and checkout. == Changelog == = 8.5.0 - 2024-xx-xx = * Fix - When using a saved payment method, update the payment method's address immediately upon checkout. Fixes issues where Stripe may throw address validation errors. * Add - Allow customizing the title and description of the UPE payment methods. * Tweak - Add a statement descriptor preview for Cash App Payments. [See changelog for all versions](https://raw.githubusercontent.com/woocommerce/woocommerce-gateway-stripe/trunk/changelog.txt).
Originally reported here.
Reference from old version: https://github.com/woothemes/woocommerce-gateway-stripe-private/blob/master/includes/class-wc-gateway-stripe.php#L606
Where to add: https://github.com/woothemes/woocommerce-gateway-stripe/blob/master/includes/class-wc-gateway-stripe.php#L513-L514
Related ticket: 430935-zd-woothemes
Notice: Use of undefined constant WC_VERSION - assumed 'WC_VERSION' in /srv/www/wc.demo/htdocs/wp-content/plugins/woocommerce-gateway-stripe/woocommerce-gateway-stripe.php on line 193
Notice: Use of undefined constant WC_VERSION - assumed 'WC_VERSION' in /srv/www/wc.demo/htdocs/wp-content/plugins/woocommerce-gateway-stripe/woocommerce-gateway-stripe.php on line 199
The plugin could not be activated. The minimum WooCommerce version required for this plugin is 2.5.0. You are running WC_VERSION.
Make sure to check whether WC_VERSION
is defined or not.
Previously: https://github.com/woothemes/woocommerce-gateway-stripe-private/issues/112
When the user forgets to select the saved card, it will correctly stop the transaction - but no notice is displayed to inform the customer: http://cld.wthms.co/1fDww/4vs1NvpW
Link to the ticket: https://woothemes.zendesk.com/agent/tickets/425806
I expected to be able to change the default selected payment method using the Gateway Order Display - WooCommerce > Settings > Checkout > Gateway Order Display.
When a customer has a saved card, Stripe is always the default payment gateway regardless of the payment gateway order in the Gateway Order Display.
Using WooCommerce 2.6.3 and Stripe 3.0.2
What I expected
I expected to be able to go to example.com/add-payment-method to add a Stripe credit card to my Stripe account and then immediately see the new card that was added.
What happened instead
Weird Bug: After saving new cards with either the add new payment method (or just in checkout), the example.com/payment-methods/ doesn't show the newly added card(s) (example: https://cloudup.com/c1P73p_IF_E), until I add a new item to the cart, and load the checkout page. On the checkout page the new cards show - and then if I reload example.com/payment-methods/ even without completing the checkout - it shows all the cards that have been added (no matter what they were added by).
Using:
• Storefront 2.0
• Woocommerce 2.6 Beta 3
• WooCommerce Stripe Payment Gateway 3.0 (latest commit as of today)
I've submitted a patch for WooCommerce Core that would allow for plugins to declare settings fields as secure: woocommerce/woocommerce#11946 . This allows other plugins to then secure the keys prior to storage.
To enable this, we simply put a 'secure' => true,
into the field array. Then when getting the settings in the construct, we run through the fields, look for a secure field and then apply the filter as needed. Also in the API we put in a filter on the live_secure_key get_option so it can work as expected.
The pull request will come right after this. I've got a few discussion points on the specifics of the code that I can discuss on it.
When a credit card is declined while adding it to the saved payment methods via My Accounts, a PHP fatal error is generated.
Steps to reproduce:
Tested this with another Stripe test card for simulating successful transactions; this card was added successfully as a payment method.
Tested on Stripe 3.0.2 (original forum post) and on Stripe 3.0.5 with minimal plugins.
Error:
[27-Sep-2016 20:11:49 UTC] PHP Fatal error: Uncaught exception ‘Exception’ with message ‘Your card was declined.’ in /nas/content/live/test2findcra/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-gateway-stripe.php:544
Stack trace:
#0 /nas/content/live/test2findcra/wp-content/plugins/woocommerce/includes/class-wc-form-handler.php(369): WC_Gateway_Stripe->add_payment_method()
#1 [internal function]: WC_Form_Handler::add_payment_method_action(Object(WP))
#2 /nas/content/live/test2findcra/wp-includes/plugin.php(600): call_user_func_array(Array, Array)
#3 /nas/content/live/test2findcra/wp-includes/class-wp.php(738): do_action_ref_array(‘wp’, Array)
#4 /nas/content/live/test2findcra/wp-includes/functions.php(963): WP->main(”)
#5 /nas/content/live/test2findcra/wp-blog-header.php(16): wp()
#6 /nas/content/live/test2findcra/index.php(17): require(‘/nas/content/li…’)
#7 {main}
thrown in /nas/content/live/test2findcra/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-gateway-stripe.php on line 544
Originally reported here: https://wordpress.org/support/topic/declined-card-throws-500-error/
Hi!
I noticed with the old version 2.6.12 when user gets a “card_declined”:
– Order is saved, set to “Failed” http://screencast.com/t/IpVGllHzO
– Admin receives a “Failed order” notification
– User can try again and again, this will NOT generate new orders (just 1 order instance)
– After a successful payment the status of the same order is set to “Processing”
Now with the new version 3.0.2 when user gets a “card_declined”:
– Order is saved, set to “On hold”
– Admin nor client receives NO email notifications of a failed order
– User can try again and again, every try will generate a new order!
– After a successful payment another new order will be generated which is set to “Processing” http://screencast.com/t/N9YVUIs2KBA6
Could this be a bug? It is much cleaner when only 1 order instance is used, “Failed” is much more appropriate for a declined error, and a failed order notification to admin would be very appropriate as well !
If the option to save credit card details is activated in the admin the credit card only get's saved if the checkbox is enabled
The customer choice gets ignored and the card is always saved!
$maybe_saved_card = ! isset( $_POST['wc-stripe-new-payment-method'] ) || ! empty( $_POST['wc-stripe-new-payment-method'] );
-> ! isset( $_POST['wc-stripe-new-payment-method'] )
results too true if the key isn't present which happens on a normal submit with storefront theme ...
Now they do not.
Reported here
@tommyshellberg @slash1andy @stevetested @seanreloaded @BFTrick @dwainm @gedex
proceed to checkout without errors, for now stripe token is missing
default checkout submit is initiated before stripe actually retrieve proper token. Token is populated into form AFTER checkout submit request. There's no hook to prevent submission on entire checkout form. I made breakdown in js for myself. Checkout submit not contains stripe token, it's added after getting back errors (they are caused with missing stripe token).
Everything work well with stripe checkout enabled but i want to handle it with regular cc fields.
Plugin version: 3.0.2
Woocommerce version: 2.6.4
WP version: 4.6.1
all is up to date, no other plugins that affect on submit process.
Since WC 2.6 offer Stripe installation via on-boarding wizard, it'd be helpful to render notice info that directs merchant to Stripe checkout setting.
Proposed wording:
Stripe is almost ready.* To get started, connect your Stripe account.
and then link the “connect your Stripe” text to the settings screen for the gateway.
Hi guys,
When a customer doesn't enter any card info in the stripe form on the checkout page (integrated form, NOT the checkout.js version), the error message they see is "Could not find payment information". Could you please change this to something more consumer friendly, eg. "Please enter your card information"?
Cheers
"Stripe is enabled, but the force SSL option is disabled; your checkout may not be secure! Please enable SSL and ensure your server has a valid SSL certificate - Stripe will only work in test mode."
Either add a filter to optionally remove this notice, or don't display it when the plugin is already in test mode. Would be helpful with all the local dev setups to not see this all the time.
The following warning shows up frequently in our logs:
ErrorException: Missing argument 1 for WC_Stripe_Customer::create_customer(), called in /home/defender-pro_com/www/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-stripe-customer.php on line 167 and defined
File "/home/defender-pro_com/www/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-stripe-customer.php", line 124, in handleError
public function create_customer( $args ) {
File "/home/defender-pro_com/www/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-stripe-customer.php", line 124, in create_customer
public function create_customer( $args ) {
File "/home/defender-pro_com/www/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-stripe-customer.php", line 167, in add_card
if ( ( $response = $this->create_customer() ) && is_wp_error( $response ) ) {
File "/home/defender-pro_com/www/wp-content/plugins/woocommerce-gateway-stripe/includes/legacy/class-wc-gateway-stripe.php", line 368, in get_source
$stripe_source = $stripe_customer->add_card( $stripe_token );
File "/home/defender-pro_com/www/wp-content/plugins/woocommerce-gateway-stripe/includes/legacy/class-wc-gateway-stripe.php", line 431, in process_payment
$source = $this->get_source( get_current_user_id(), $force_customer );
File "/home/defender-pro_com/www/wp-content/plugins/woocommerce/includes/class-wc-checkout.php", line 643, in process_checkout
$result = $available_gateways[ $this->posted['payment_method'] ]->process_payment( $order_id );
File "/home/defender-pro_com/www/wp-content/plugins/woocommerce/includes/class-wc-ajax.php", line 450, in checkout
WC()->checkout()->process_checkout();
File "/home/defender-pro_com/www/wordpress/wp-includes/plugin.php", line 525, in do_action
call_user_func_array($the_['function'], array_slice($args, 0, (int) $the_['accepted_args']));
File "/home/defender-pro_com/www/wp-content/plugins/woocommerce/includes/class-wc-ajax.php", line 82, in do_wc_ajax
do_action( 'wc_ajax_' . sanitize_text_field( $action ) );
File "/home/defender-pro_com/www/wordpress/wp-includes/plugin.php", line 525, in do_action
call_user_func_array($the_['function'], array_slice($args, 0, (int) $the_['accepted_args']));
File "/home/defender-pro_com/www/wordpress/wp-includes/template-loader.php", line 12, in require_once
do_action( 'template_redirect' );
File "/home/defender-pro_com/www/wordpress/wp-blog-header.php", line 19, in require
require_once( ABSPATH . WPINC . '/template-loader.php' );
File "/home/defender-pro_com/www/index.php", line 17
require( __DIR__ . '/wordpress/wp-blog-header.php' );
Possible cause is from this line: https://github.com/woothemes/woocommerce-gateway-stripe/blob/master/assets/js/stripe.js#L90. Where elements for first name and last name didn't exists, but then wc_stripe_params.billing_first_name
and wc_stripe_params.billing_last_name
were also undefined
.
Please note that the order notes include the Stripe transaction details
Please note that the Stripe transaction detail has been missed
@tommyshellberg @slash1andy @stevetested @seanreloaded @BFTrick @gedex
Stripe supports ApplePay for the Web via stripe.js :https://stripe.com/docs/apple-pay
Support for Apple Pay is heavily requested on Ideas board as well: http://ideas.woothemes.com/forums/133476-woocommerce/suggestions/6430486-add-apple-pay-support-to-woocommerce
Is this planned for a future release?
See details here woocommerce/woocommerce#11741
On submitting the credit card form I expected to see a ui block with a spinner.
A white overlay appears only blocking the form with no indication of activity. On themes with sticky headers this header is not blocked, header navigation is still possible.
Checkout on mobile
See \woocommerce-gateway-stripe\assets\js\stripe.js lines 70 ~ 150
Currently the UI block is applied to the form which is above the screen when pressing the checkout button.
Our solution is to create a second full UI blocking function (call blockUI without an element) and only use this function on submission of the form.
See our hacky solution below. I'm sure you can come up with something better!
Block functions:
block: function() {
wc_stripe_form.form.block({
message: null,
overlayCSS: {
background: '#fff',
opacity: 0.6
}
});
},
fullBlock: function() {
$.blockUI({
message: null,
overlayCSS: {
background: '#fff',
opacity: 0.6
}
});
},
unblock: function() {
wc_stripe_form.form.unblock();
$.unblockUI();
},
During submit:
onSubmit: function( e ) {
if ( wc_stripe_form.isStripeChosen() && ! wc_stripe_form.hasToken() ) {
e.preventDefault();
wc_stripe_form.fullBlock();
Detect event from Woocommerce:
$( document.body ).on( 'checkout_error', function() {
$.unblockUI();
});
Error messages on failure of payment are returned in english. They should be translatable.
Below a defined list of error codes
invalid_number The card number is not a valid credit card number.
invalid_expiry_month The card's expiration month is invalid.
invalid_expiry_year The card's expiration year is invalid.
invalid_cvc The card's security code is invalid.
incorrect_number The card number is incorrect.
expired_card The card has expired.
incorrect_cvc The card's security code is incorrect.
incorrect_zip The card's zip code failed validation.
card_declined The card was declined.
missing There is no card on a customer that is being charged.
processing_error An error occurred while processing the card.
This is the second time I've seen this issue now. Users will sometimes accidentally swap their test credentials with their live credentials.
If we could write some very basic validation we could help users figure this out. Also help ourselves figure this out.
test
in themlive
in themWould be nice to use JS to do this to let users know immediately when they make a mistake rather than tell them about 4 mistakes after they save the page.
We've deployed this gateway for two Japanese websites and found it's impossible to input card numbers while using a Japanese iOS keyboard.
Please see following bug demo video.
https://www.youtube.com/watch?v=MEpelmggcsE
I've typed 424242 but 4244242422 has appeared
With Stripe Checkout enabled, click the Proceed to payment button and the Stripe payment form appears as an overlay.
Click the Proceed to payment button and the page scrolls to the top then shows the error:
Please enter your card details to make a payment. Developers: Please make sure that you are including jQuery and there are no JavaScript errors on the page.
I'm also seeing a javascript error in Safari's web tools:
#### Steps to reproduce the issueReferenceError: Can't find variable: $required_inputs
I disabled all plugins except WooCommerce and Stripe 3.0.4 then went through the checkout process. This was also happening in a prior version but I'm not sure if it was 3.0.2 or 3.0.3. The problem was fixed when I rolled back to version 3.0.0.
There's a post with a possible fix over in the WordPress support forums that looks like it could be this same issue. https://wordpress.org/support/topic/v3-0-4-breaks-checkout-button-developers-xxx/
For my WooCommerce Pre-Orders to be in a pre-order status when paying with stripe - see ticket: #430712-zd-woothemes
With the combination of WooCommerce 2.5.5 (edited, version doesn't seem to matter), Subscriptions (edit - added subscriptions to the mix), Pre-Orders 1.4.5 and Stripe >= 3.0.0 pre-order items have their payment collected immediately
updating to WooCommerce 2.6 installing/activating Subscriptions will solve this as will downgrading to Stripe 2.6.12
Suggested by @jobthomas : Credit Card (Stripe)
instead of Credit card (Stripe)
When the Enable Stripe Checkout box is checked, the form in the modal popup checks the billing address.
When the Enable Stripe Checkout box is checked, the form in the modal popup checks only the origin and CVC
In a live environment, check the Stripe Checkout box and then enter credit card information in the modal popup on front-end checkout.
Relevant code at line 110 of https://github.com/woothemes/woocommerce-gateway-stripe/blob/master/assets/js/stripe_checkout.js:
StripeCheckout.open({
key : wc_stripe_params.key,
address : false,
the woocommerce stripe gateway accepts JCB credit cards
when entering a JCB card, the stripe modal popup just blinks, gives no auth, no error, to denial message, no processing indicator. The gateway is sending nothing to Stripe...there is no record of the attempt on the Stripe site.
Using Stripe gateway 3.0.2.
woocommerce 2.6.4
WordPress 4.6
VISA and AmEx cards auth and capture with no problem. With the same setup and same processes for JCB I get no response from the woocommerce strip gateway.
All the documentation indicates JCB is accepted. Please help.
Thanks,
Craig
PLEASE NOTE
Wrong object returned from stripe is being used, causing localised error messages to not display.
stripe.js l:93
Broken:
if ( wc_stripe_params.hasOwnProperty( responseObject.response.error.code ) ) {
message = wc_stripe_params[ responseObject.response.error.code ];
}
Fixed:
if ( wc_stripe_params.hasOwnProperty( responseObject.response.error.type ) ) {
message = wc_stripe_params[ responseObject.response.error.type ];
}
Source: https://wordpress.org/support/topic/error-message-localization-broken/
Hi,
I'm having an intermittent issue with some orders, where the plugin makes the request to Stripe, Stripe charges the customer, and then... nothing. I seems like the plugin doesn't receive a response, or quits listening for one.
I'm at a bit of a loss here since I don't see how it could just stop working between lines 57 and 71 in class-wc-stripe-api.php
.
Things I've checked/tried:
I'm not sure if this is even an issue with the plugin, but since I can't reproduce it reliably, it's very hard to debug. I'm hoping this rings a bell for someone who can either identify the issue or point me in a direction to narrow down the problem.
Thank you
Reported by @conschneider on Account Funds
Blocked from choosing another method on checkout after selecting strip and the sub-options 😳
This is what happens: https://cloudup.com/c6JTUNW1Nkv
Ticket: https://woothemes.zendesk.com/agent/tickets/456053
We have Stripe and Check as payment options. This radio seems to trigger the check payment method, however the label is missing. I expected the label to display.
#### What happened insteadThe label for check payment is missing.
Enable Stripe and Check payment methods.
Enable test mode for Stripe.
Go to checkout.
Because the created card outside of the normal checkout does not add the address in the stripe request - reducing fraud detection e.g.
When a brand new customer (can't use an existing customer or email) makes a purchase they'll show up with just the first name in the Description
field under the Customers
menu in Stripe. We should change this to show the full name.
PHP Fatal error: Call to a member function get_error_code() on a non-object in /srv/www/wordpress-default/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-stripe-customer.php on line 177
[23-May-2016 05:35:09 UTC] PHP Notice: Undefined variable: result in /srv/www/wordpress-default/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-stripe-customer.php on line 177
As of this writing, 3D secure is in beta. Adding this would be a good feature.
Would love an easy way for someone to delete the Stripe customer profile that is created by Stripe and saved in WooCommerce.
This has to be done in the database, which can be daunting to many of our users. The typical use case is when someone uses their own user for testing purposes, which has a test mode user created in Stripe. When they move the gateway to live, they need to delete the Stripe customer associated with the WordPress user in order to be able to test the live mode, but it's almost easier for them to just delete the entire WordPress user than find the row in wp_usermeta
.
What I would love to see is the row showing the Stripe customer info in the users' page in WordPress, but obviously I defer to y'all :)
CC: @gedex
Users should be able to customize the credit card icons they accept.
We've simplified it to if you accept USD you should display all CC icons but that's an oversimplification. There are Canadian accounts which accept USD and they can only accept: Visa, Mastercard, & Amex.
$icon = '<img src="' . WC_HTTPS::force_https_url( WC()->plugin_url() . '/assets/images/icons/credit-cards/visa' . $ext ) . '" alt="Visa" width="32" ' . $style . ' />';
$icon .= '<img src="' . WC_HTTPS::force_https_url( WC()->plugin_url() . '/assets/images/icons/credit-cards/mastercard' . $ext ) . '" alt="Mastercard" width="32" ' . $style . ' />';
$icon .= '<img src="' . WC_HTTPS::force_https_url( WC()->plugin_url() . '/assets/images/icons/credit-cards/amex' . $ext ) . '" alt="Amex" width="32" ' . $style . ' />';
if ( 'USD' === get_woocommerce_currency() ) {
$icon .= '<img src="' . WC_HTTPS::force_https_url( WC()->plugin_url() . '/assets/images/icons/credit-cards/discover' . $ext ) . '" alt="Discover" width="32" ' . $style . ' />';
$icon .= '<img src="' . WC_HTTPS::force_https_url( WC()->plugin_url() . '/assets/images/icons/credit-cards/jcb' . $ext ) . '" alt="JCB" width="32" ' . $style . ' />';
$icon .= '<img src="' . WC_HTTPS::force_https_url( WC()->plugin_url() . '/assets/images/icons/credit-cards/diners' . $ext ) . '" alt="Diners" width="32" ' . $style . ' />';
}
Rather than trying to keep up with what types of Stripe accounts & currencies accept which types of cards we should let users display the CC icons they want to display.
Originally from: https://woothemes.zendesk.com/agent/tickets/434817
The Stripe customer/card tokens set on a subscription to be honoured when processing renewal payments.
The customer ID stored in user meta against the subscription's customer_user
was used when the payment failed using the customer/card tokens set on the subscription.
SHA: fb1cdf4 introduced a basic retry system to scheduled_subscription_payment()
which would fallback to use the Stripe customer token set in user meta if the payment fails, for any reason, using customer/card tokens set on the subscription.
This becomes an issue if the customer was expecting to be able to use certain cards for certain subscriptions. For example, a customer may use a company credit card for one subscription, while using a personal card for other purchases in the same store. Or one customer may purchase a subscription for someone else and use that person's credit card for the payments instead of their own (like you might do for your grandmother to save her having to mess with the tech). (These issues aren't entirely new, Stripe has defaulted to user meta for getting a customer ID for a long time, but only when there was no customer/card token set on the subscription, not whenever a payment fails for any reason).
Subscriptions is introducing its own retry system into v2.1 (for full details, see: https://github.com/Prospress/woocommerce-subscriptions/pull/1298). While that is quite a different approach and not quite as elegant as this one (as it has to be payment gateway agnostic), it's probably a sufficient substitute to the system introduced with SHA: fb1cdf4.
Because of these issues and the impeding alternative, I think this retry system should be removed from scheduled_subscription_payment()
.
If you guys agree, let me know and I'll submit a PR. 😄
If a customer by mistake enteres a wrong CVC, I expected to see an error message they can correct their mistake.
Instead, the user gets a white screen.
Fatal error: Uncaught exception 'Exception' with message 'Your card's security code is incorrect.' in /storage/content/81/151281/japanmysterybox.com/public_html/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-gateway-stripe.php:544
On the the My Account page, select the Payment Methods tab.
Click "Add Payment Method"
Use the card number 4000000000000127 (following these testing card numbers: https://cloudup.com/c0EOTyt_3rM)
https://cloudup.com/cYQ_nbrwOKa
Use an expiry and CVC then click Add Card.
Voilá, white screen.
It seems to work when Stripe is in test mode, but doesn't work when live (tested by ProsPress)
459374-zd-woothemes
When Partial Payments is enabled in the WooCommerce Account Funds plugin settings, I would expect only 4 GBP to be charged via Stripe as 32 GBP were paid for via Account Funds:
The Account Funds were removed from the user's account, which is correct, but the full amount of 36 GBP was send to Stripe:
The Stripe log says the following:
09-08-2016 @ 06:45:56 - Info: Begin processing payment for order 587 for the amount of 36
Here's the Stripe dashboard:
466156-zd-woothemes
Prior to upgrade with WooCommerce 2.5.5 with Stripe 3.0.2
After performing the upgrade to WooCommerce 3.6.1 with Stripe 3.0.2
zd-woothemes-432332
If i submit the Form the card get checked once with https://api.stripe.com/v1/tokens
https://api.stripe.com/v1/token
the request to https://api.stripe.com/v1/tokens is done twice
onSubmit is fired twice -> https://github.com/woothemes/woocommerce-gateway-stripe/blob/master/assets/js/stripe.js#L28
once for submit
and once for checkout_place_order_stripe because of https://github.com/woothemes/woocommerce/blob/f4a30e3be630caad8c8c0392885a136ed4fd9f67/assets/js/frontend/checkout.js#L349
is this done on purpose or a bug?
Here's the notice:
PHP Notice: Trying to get property of non-object in /srv/www/wordpress-default/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-gateway-stripe.php on line 488
I believe $source->source
is a string, containing token, instead of an object.
Lets see if there's a way we can enforce TLS 1.2, when using wp_remote_post()
, as we do.
submitted by @danieldudzic on old repo
Not sure, if this is something we want to add, but thought I'd pass it along for review.
A customer needed to have specific order information from Product Add-ons added to every order in the Stripe UI.
I was hoping for a filter close to line 547 in the file class-wc.gateway-stripe.php but to no avail.
This means I had to edit this file directly, and changed the line below"$post_data['description'] = sprintf( __( '%s - Order %s', 'woocommerce-gateway-stripe' ), wp_specialchars_decode( get_bloginfo( 'name' ), ENT_QUOTES ), $order->get_order_number() );"
in order to get the specific information my client wanted.
Anyhow, I was wondering if there is a chance to add a filter just for description, as I think I can't be the only one wanting this.So, please add a filter to the Stripe order description and include the current $order so I am able to extract my needed information.
Link to the ticket: https://woothemes.zendesk.com/agent/tickets/408464
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.