You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* removed html from translatable strings that are still in use #2199
* add changelog #2199
* Removed scaping where it was not needed and added on some places that it was needed.
* standardized all translators: comments #2199
* Removed htlm scape on where it was unecessary #2199
* added url escape to get_setting_link #2199
Co-authored-by: Danae Millan <[email protected]>
Copy file name to clipboardExpand all lines: includes/abstracts/abstract-wc-stripe-payment-gateway-voucher.php
+7-3Lines changed: 7 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -104,9 +104,13 @@ abstract class WC_Stripe_Payment_Gateway_Voucher extends WC_Stripe_Payment_Gatew
104
104
* @since 5.8.0
105
105
*/
106
106
publicfunction__construct() {
107
-
/* translators: link */
108
-
$this->method_description = sprintf( __( 'All other general Stripe settings can be adjusted <a href="%s">here</a>.', 'woocommerce-gateway-stripe' ), admin_url( 'admin.php?page=wc-settings&tab=checkout§ion=stripe' ) );
109
-
$this->supports = [
107
+
$this->method_description = sprintf(
108
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
109
+
__( 'All other general Stripe settings can be adjusted %1$shere%2$s ', 'woocommerce-gateway-stripe' ),
/* translators: 1) A URL that explains Stripe Radar. */
136
-
$message = __( 'WooCommerce Stripe - We see that you had the "Require 3D secure when applicable" setting turned on. This setting is not available here anymore, because it is now replaced by Stripe Radar. You can learn more about it <a href="%s" target="_blank">here</a>.', 'woocommerce-gateway-stripe' );
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
137
+
__( 'WooCommerce Stripe - We see that you had the "Require 3D secure when applicable" setting turned on. This setting is not available here anymore, because it is now replaced by Stripe Radar. You can learn more about it %1$shere%2$s ', 'woocommerce-gateway-stripe' ),
$message = __( 'WooCommerce Stripe - We recently made changes to Stripe that may impact the appearance of your checkout. If your checkout has changed unexpectedly, please follow these <a href="https://woocommerce.com/document/stripe/#new-checkout-experience" target="_blank">instructions</a> to fix.', 'woocommerce-gateway-stripe' );
146
+
$message = sprintf(
147
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
148
+
__( 'WooCommerce Stripe - We recently made changes to Stripe that may impact the appearance of your checkout. If your checkout has changed unexpectedly, please follow these %1$sinstructions%2$s to fix.', 'woocommerce-gateway-stripe' ),
if ( empty( $secret ) && $should_show_notice_on_page ) {
183
191
$setting_link = $this->get_setting_link();
184
-
/* translators: 1) link */
185
-
$this->add_admin_notice( 'keys', 'notice notice-warning', sprintf( __( 'Stripe is almost ready. To get started, <a href="%s">set your Stripe account keys</a>.', 'woocommerce-gateway-stripe' ), $setting_link ), true );
192
+
193
+
$notice_message = sprintf(
194
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
195
+
__( 'Stripe is almost ready. To get started, %1$sset your Stripe account keys%2$s.', 'woocommerce-gateway-stripe' ),
if ( ! $is_test_pub_key || ! $is_test_secret_key ) {
193
207
$setting_link = $this->get_setting_link();
194
-
/* translators: 1) link */
195
-
$this->add_admin_notice( 'keys', 'notice notice-error', sprintf( __( 'Stripe is in test mode however your test keys may not be valid. Test keys start with pk_test and sk_test or rk_test. Please go to your settings and, <a href="%s">set your Stripe account keys</a>.', 'woocommerce-gateway-stripe' ), $setting_link ), true );
208
+
209
+
$notice_message = sprintf(
210
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
211
+
__( 'Stripe is in test mode however your test keys may not be valid. Test keys start with pk_test and sk_test or rk_test. Please go to your settings and, %1$sset your Stripe account keys%2$s.', 'woocommerce-gateway-stripe' ),
if ( ! $is_live_pub_key || ! $is_live_secret_key ) {
201
222
$setting_link = $this->get_setting_link();
202
-
/* translators: 1) link */
203
-
$this->add_admin_notice( 'keys', 'notice notice-error', sprintf( __( 'Stripe is in live mode however your live keys may not be valid. Live keys start with pk_live and sk_live or rk_live. Please go to your settings and, <a href="%s">set your Stripe account keys</a>.', 'woocommerce-gateway-stripe' ), $setting_link ), true );
223
+
224
+
$message = sprintf(
225
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
226
+
__( 'Stripe is in live mode however your live keys may not be valid. Live keys start with pk_live and sk_live or rk_live. Please go to your settings and, %1$sset your Stripe account keys%2$s.', 'woocommerce-gateway-stripe' ),
$this->add_admin_notice( 'keys', 'notice notice-error', sprintf( __( 'Your customers cannot use Stripe on checkout, because we couldn\'t connect to your account. Please go to your settings and, <a href="%s">set your Stripe account keys</a>.', 'woocommerce-gateway-stripe' ), $setting_link ), true );
239
+
240
+
$message = sprintf(
241
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
242
+
__( 'Your customers cannot use Stripe on checkout, because we couldn\'t connect to your account. Please go to your settings and, %1$sset your Stripe account keys%2$s.', 'woocommerce-gateway-stripe' ),
// Show message if enabled and FORCE SSL is disabled and WordpressHTTPS plugin is not detected.
218
253
if ( ! wc_checkout_is_https() ) {
219
-
/* translators: 1) link */
220
-
$this->add_admin_notice( 'ssl', 'notice notice-warning', sprintf( __( 'Stripe is enabled, but a SSL certificate is not detected. Your checkout may not be secure! Please ensure your server has a valid <a href="%1$s" target="_blank">SSL certificate</a>', 'woocommerce-gateway-stripe' ), 'https://en.wikipedia.org/wiki/Transport_Layer_Security' ), true );
254
+
$message = sprintf(
255
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
256
+
__( 'Stripe is enabled, but a SSL certificate is not detected. Your checkout may not be secure! Please ensure your server has a valid %1$sSSL certificate%2$s.', 'woocommerce-gateway-stripe' ),
$this->add_admin_notice( 'sca', 'notice notice-success', sprintf( __( 'Stripe is now ready for Strong Customer Authentication (SCA) and 3D Secure 2! <a href="%1$s" target="_blank">Read about SCA</a>', 'woocommerce-gateway-stripe' ), 'https://woocommerce.com/posts/introducing-strong-customer-authentication-sca/' ), true );
266
+
$message = sprintf(
267
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
268
+
__( 'Stripe is now ready for Strong Customer Authentication (SCA) and 3D Secure 2! %1$sRead about SCA%2$s.', 'woocommerce-gateway-stripe' ),
$this->add_admin_notice( 'changed_keys', 'notice notice-warning', sprintf( __( 'The public and/or secret keys for the Stripe gateway have been changed. This might cause errors for existing customers and saved payment methods. <a href="%s" target="_blank">Click here to learn more</a>.', 'woocommerce-gateway-stripe' ), 'https://woocommerce.com/document/stripe-fixing-customer-errors' ), true );
277
+
$message = sprintf(
278
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
279
+
__( 'The public and/or secret keys for the Stripe gateway have been changed. This might cause errors for existing customers and saved payment methods. %1$sClick here to learn more%2$s.', 'woocommerce-gateway-stripe' ),
@@ -250,7 +303,7 @@ public function payment_methods_check_environment() {
250
303
}
251
304
252
305
if ( ! in_array( get_woocommerce_currency(), $gateway->get_supported_currency(), true ) ) {
253
-
/* translators: %1$s Payment method, %2$s List of supported currencies */
306
+
/* translators: 1) Payment method, 2) List of supported currencies */
254
307
$this->add_admin_notice( $method, 'notice notice-error', sprintf( __( '%1$s is enabled - it requires store currency to be set to %2$s', 'woocommerce-gateway-stripe' ), $gateway->get_method_title(), implode( ', ', $gateway->get_supported_currency() ) ), true );
255
308
}
256
309
}
@@ -366,7 +419,7 @@ public function hide_notices() {
returnwpautop( sprintf( __( 'By using this extension, you may be storing personal data or sharing data with an external service. <a href="%s" target="_blank">Learn more about how this works, including what you may want to include in your privacy policy.</a>', 'woocommerce-gateway-stripe' ), 'https://woocommerce.com/document/privacy-payments/#section-3' ) );
92
+
93
+
$message = sprintf(
94
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
95
+
esc_html__( 'By using this extension, you may be storing personal data or sharing data with an external service. %1$sLearn more about how this works, including what you may want to include in your privacy policy%2$s.', 'woocommerce-gateway-stripe' ),
@@ -102,12 +102,16 @@ public function admin_scripts( $hook_suffix ) {
102
102
$oauth_url = '';
103
103
}
104
104
105
+
$message = sprintf(
106
+
/* translators: 1) Html strong opening tag 2) Html strong closing tag */
107
+
esc_html__( '%1$sWarning:%2$s your site\'s time does not match the time on your browser and may be incorrect. Some payment methods depend on webhook verification and verifying webhooks with a signing secret depends on your site\'s time being correct, so please check your site\'s time before setting a webhook secret. You may need to contact your site\'s hosting provider to correct the site\'s time.', 'woocommerce-gateway-stripe' ),
108
+
'<strong>',
109
+
'</strong>'
110
+
);
111
+
105
112
$params = [
106
113
'time' => time(),
107
-
'i18n_out_of_sync' => wp_kses(
108
-
__( '<strong>Warning:</strong> your site\'s time does not match the time on your browser and may be incorrect. Some payment methods depend on webhook verification and verifying webhooks with a signing secret depends on your site\'s time being correct, so please check your site\'s time before setting a webhook secret. You may need to contact your site\'s hosting provider to correct the site\'s time.', 'woocommerce-gateway-stripe' ),
/* translators: %1: transaction ID of the payment or a translated string indicating an unknown ID. */
579
-
esc_html__( 'A payment with ID %s was used in an attempt to pay for this order. This payment intent ID does not match any payments for this order, so it was ignored and the order was not updated.', 'woocommerce-gateway-stripe' ),
579
+
__( 'A payment with ID %s was used in an attempt to pay for this order. This payment intent ID does not match any payments for this order, so it was ignored and the order was not updated.', 'woocommerce-gateway-stripe' ),
$message = sprintf( __( 'A dispute was created for this order. Response is needed. Please go to your <a href="%s" title="Stripe Dashboard" target="_blank">Stripe Dashboard</a> to review this dispute.', 'woocommerce-gateway-stripe' ), $this->get_transaction_url( $order ) );
315
+
$message = sprintf(
316
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
317
+
__( 'A dispute was created for this order. Response is needed. Please go to your %1$sStripe Dashboard%2$s to review this dispute.', 'woocommerce-gateway-stripe' ),
/* translators: 1) The URL to the order. 2) The reason type. */
704
-
$message = sprintf( __( 'A review has been opened for this order. Action is needed. Please go to your <a href="%1$s" title="Stripe Dashboard" target="_blank">Stripe Dashboard</a> to review the issue. Reason: (%2$s)', 'woocommerce-gateway-stripe' ), $this->get_transaction_url( $order ), $notification->data->object->reason );
708
+
$message = sprintf(
709
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag 3) The reason type. */
710
+
__( 'A review has been opened for this order. Action is needed. Please go to your %1$sStripe Dashboard%2$s to review the issue. Reason: (%3$s).', 'woocommerce-gateway-stripe' ),
Copy file name to clipboardExpand all lines: includes/notes/class-wc-stripe-upe-availability-note.php
+7-1Lines changed: 7 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -36,7 +36,13 @@ public static function get_note() {
36
36
$note = new$note_class();
37
37
38
38
$note->set_title( __( 'Boost your sales with the new payment experience in Stripe', 'woocommerce-gateway-stripe' ) );
39
-
$note->set_content( __( 'Get early access to an improved checkout experience, now available to select merchants. <a href="https://woocommerce.com/document/stripe/#new-checkout-experience" target="_blank">Learn more</a>.', 'woocommerce-gateway-stripe' ) );
39
+
$message = sprintf(
40
+
/* translators: 1) HTML anchor open tag 2) HTML anchor closing tag */
41
+
__( 'Get early access to an improved checkout experience, now available to select merchants. %1$sLearn more%2$s.', 'woocommerce-gateway-stripe' ),
$this->method_description = sprintf( __( 'All other general Stripe settings can be adjusted <a href="%s">here</a>.', 'woocommerce-gateway-stripe' ), admin_url( 'admin.php?page=wc-settings&tab=checkout§ion=stripe' ) );
0 commit comments