Merge branch 'master' of github.com:woocommerce/woocommerce

This commit is contained in:
Claudio Sanches 2017-02-24 17:20:36 -03:00
commit 53c2fe0c34
5 changed files with 21 additions and 15 deletions

View File

@ -217,7 +217,7 @@ class WC_Admin_Setup_Wizard {
?>
<h1><?php _e( 'Page setup', 'woocommerce' ); ?></h1>
<form method="post">
<p><?php printf( __( 'Your store needs a few essential %1$spages%2$s. The following will be created automatically (if they do not already exist):', 'woocommerce' ), '<a href="' . esc_url( admin_url( 'edit.php?post_type=page' ) ) . '" target="_blank">', '</a>' ); ?></p>
<p><?php printf( __( 'Your store needs a few essential <a href="%s" target="_blank">pages</a>. The following will be created automatically (if they do not already exist):', 'woocommerce' ), esc_url( admin_url( 'edit.php?post_type=page' ) ) ); ?></p>
<table class="wc-setup-pages" cellspacing="0">
<thead>
<tr>
@ -249,7 +249,7 @@ class WC_Admin_Setup_Wizard {
</tbody>
</table>
<p><?php printf( __( 'Once created, these pages can be managed from your admin dashboard on the %1$sPages screen%2$s. You can control which pages are shown on your website via %3$sAppearance > Menus%4$s.', 'woocommerce' ), '<a href="' . esc_url( admin_url( 'edit.php?post_type=page' ) ) . '" target="_blank">', '</a>', '<a href="' . esc_url( admin_url( 'nav-menus.php' ) ) . '" target="_blank">', '</a>' ); ?></p>
<p><?php printf( __( 'Once created, these pages can be managed from your admin dashboard on the <a href="%1$s" target="_blank">Pages screen</a>. You can control which pages are shown on your website via <a href="%2$s" target="_blank">Appearance > Menus</a>.', 'woocommerce' ), esc_url( admin_url( 'edit.php?post_type=page' ) ), esc_url( admin_url( 'nav-menus.php' ) ) ); ?></p>
<p class="wc-setup-actions step">
<input type="submit" class="button-primary button button-large button-next" value="<?php esc_attr_e( 'Continue', 'woocommerce' ); ?>" name="save_step" />
@ -311,7 +311,7 @@ class WC_Admin_Setup_Wizard {
}
?>
</select>
<span class="description"><?php printf( __( 'If your currency is not listed you can %1$sadd it later%2$s.', 'woocommerce' ), '<a href="https://docs.woocommerce.com/document/add-a-custom-currency-symbol/" target="_blank">', '</a>' ); ?></span>
<span class="description"><?php printf( __( 'If your currency is not listed you can <a href="%s" target="_blank">add it later</a>.', 'woocommerce' ), 'https://docs.woocommerce.com/document/add-a-custom-currency-symbol/' ); ?></span>
</td>
</tr>
<tr>
@ -454,7 +454,7 @@ class WC_Admin_Setup_Wizard {
?>
<tr class="tax-rates">
<td colspan="2">
<p><?php printf( __( 'The following tax rates will be imported automatically for you. You can read more about taxes in %1$sour documentation%2$s.', 'woocommerce' ), '<a href="https://docs.woocommerce.com/document/setting-up-taxes-in-woocommerce/" target="_blank">', '</a>' ); ?></p>
<p><?php printf( __( 'The following tax rates will be imported automatically for you. You can read more about taxes in <a href="%s" target="_blank">our documentation</a>.', 'woocommerce' ), 'https://docs.woocommerce.com/document/setting-up-taxes-in-woocommerce/' ); ?></p>
<div class="importing-tax-rates">
<table class="tax-rates">
<thead>
@ -481,7 +481,7 @@ class WC_Admin_Setup_Wizard {
</tbody>
</table>
</div>
<p class="description"><?php printf( __( 'You may need to add/edit rates based on your products or business location which can be done from the %1$stax settings%2$s screen. If in doubt, speak to an accountant.', 'woocommerce' ), '<a href="' . admin_url( 'admin.php?page=wc-settings&tab=tax' ) . '" target="_blank">', '</a>' ); ?></p>
<p class="description"><?php printf( __( 'You may need to add/edit rates based on your products or business location which can be done from the <a href="%s" target="_blank">tax settings</a> screen. If in doubt, speak to an accountant.', 'woocommerce' ), esc_url( admin_url( 'admin.php?page=wc-settings&tab=tax' ) ) ); ?></p>
</td>
</tr>
<?php
@ -564,21 +564,21 @@ class WC_Admin_Setup_Wizard {
'paypal-braintree' => array(
'name' => __( 'PayPal by Braintree', 'woocommerce' ),
'image' => WC()->plugin_url() . '/assets/images/paypal-braintree.png',
'description' => sprintf( __( 'Safe and secure payments using credit cards or your customer\'s PayPal account. %1$sLearn more about PayPal%2$s.', 'woocommerce' ), '<a href="https://wordpress.org/plugins/woocommerce-gateway-paypal-powered-by-braintree/" target="_blank">', '</a>' ),
'description' => sprintf( __( 'Safe and secure payments using credit cards or your customer\'s PayPal account. <a href="%s" target="_blank">Learn more about PayPal</a>.', 'woocommerce' ), 'https://wordpress.org/plugins/woocommerce-gateway-paypal-powered-by-braintree/' ),
'class' => 'featured featured-row-last',
'repo-slug' => 'woocommerce-gateway-paypal-powered-by-braintree',
),
'paypal-ec' => array(
'name' => __( 'PayPal Express Checkout', 'woocommerce' ),
'image' => WC()->plugin_url() . '/assets/images/paypal.png',
'description' => sprintf( __( 'Safe and secure payments using credit cards or your customer\'s PayPal account. %1$sLearn more about PayPal%2$s.', 'woocommerce' ), '<a href="https://wordpress.org/plugins/woocommerce-gateway-paypal-express-checkout/" target="_blank">', '</a>' ),
'description' => sprintf( __( 'Safe and secure payments using credit cards or your customer\'s PayPal account. <a href="%s" target="_blank">Learn more about PayPal</a>.', 'woocommerce' ), 'https://wordpress.org/plugins/woocommerce-gateway-paypal-express-checkout/' ),
'class' => 'featured featured-row-last',
'repo-slug' => 'woocommerce-gateway-paypal-express-checkout',
),
'stripe' => array(
'name' => __( 'Stripe', 'woocommerce' ),
'image' => WC()->plugin_url() . '/assets/images/stripe.png',
'description' => sprintf( __( 'A modern and robust way to accept credit card payments on your store. %1$sLearn more about Stripe%2$s.', 'woocommerce' ), '<a href="https://wordpress.org/plugins/woocommerce-gateway-stripe/" target="_blank">', '</a>' ),
'description' => sprintf( __( 'A modern and robust way to accept credit card payments on your store. <a href="%s" target="_blank">Learn more about Stripe</a>.', 'woocommerce' ), 'https://wordpress.org/plugins/woocommerce-gateway-stripe/' ),
'class' => 'featured featured-row-first',
'repo-slug' => 'woocommerce-gateway-stripe',
),
@ -641,7 +641,7 @@ class WC_Admin_Setup_Wizard {
?>
<h1><?php _e( 'Payments', 'woocommerce' ); ?></h1>
<form method="post" class="wc-wizard-payment-gateway-form">
<p><?php printf( __( 'WooCommerce can accept both online and offline payments. %2$sAdditional payment methods%3$s can be installed later and managed from the %1$scheckout settings%3$s screen.', 'woocommerce' ), '<a href="' . admin_url( 'admin.php?page=wc-settings&tab=checkout' ) . '" target="_blank">', '<a href="' . admin_url( 'admin.php?page=wc-addons&view=payment-gateways' ) . '" target="_blank">', '</a>' ); ?></p>
<p><?php printf( __( 'WooCommerce can accept both online and offline payments. <a href="%1$s" target="_blank">Additional payment methods</a> can be installed later and managed from the <a href="%2$s" target="_blank">checkout settings</a> screen.', 'woocommerce' ), esc_url( admin_url( 'admin.php?page=wc-addons&view=payment-gateways' ) ), esc_url( admin_url( 'admin.php?page=wc-settings&tab=checkout' ) ) ); ?></p>
<ul class="wc-wizard-payment-gateways">
<?php foreach ( $gateways as $gateway_id => $gateway ) : ?>

View File

@ -219,7 +219,8 @@ class WC_Admin {
if ( isset( $current_screen->id ) && apply_filters( 'woocommerce_display_admin_footer_text', in_array( $current_screen->id, $wc_pages ) ) ) {
// Change the footer text
if ( ! get_option( 'woocommerce_admin_footer_text_rated' ) ) {
$footer_text = sprintf( __( 'If you like <strong>WooCommerce</strong> please leave us a %1$s&#9733;&#9733;&#9733;&#9733;&#9733;%2$s rating. A huge thanks in advance!', 'woocommerce' ), '<a href="https://wordpress.org/support/plugin/woocommerce/reviews?rate=5#new-post" target="_blank" class="wc-rating-link" data-rated="' . esc_attr__( 'Thanks :)', 'woocommerce' ) . '">', '</a>' );
/* translators: %s: five stars */
$footer_text = sprintf( __( 'If you like <strong>WooCommerce</strong> please leave us a %s rating. A huge thanks in advance!', 'woocommerce' ), '<a href="https://wordpress.org/support/plugin/woocommerce/reviews?rate=5#new-post" target="_blank" class="wc-rating-link" data-rated="' . esc_attr__( 'Thanks :)', 'woocommerce' ) . '">&#9733;&#9733;&#9733;&#9733;&#9733;</a>' );
wc_enqueue_js( "
jQuery( 'a.wc-rating-link' ).click( function() {
jQuery.post( '" . WC()->ajax_url() . "', { action: 'woocommerce_rated' } );

View File

@ -489,7 +489,7 @@ $pages = $system_status->get_pages();
echo '<mark class="error"><span class="dashicons dashicons-warning"></span> ' . __( 'Page ID is set, but the page does not exist', 'woocommerce' ) . '</mark>';
$error = true;
} elseif ( ! $page['page_visible'] ) {
echo '<mark class="error"><span class="dashicons dashicons-warning"></span> ' . sprintf( __( 'Page visibility should be %1$spublic%2$s', 'woocommerce' ), '<a href="https://codex.wordpress.org/Content_Visibility" target="_blank">', '</a>' ) . '</mark>';
echo '<mark class="error"><span class="dashicons dashicons-warning"></span> ' . sprintf( __( 'Page visibility should be <a href="%s" target="_blank">public</a>', 'woocommerce' ), 'https://codex.wordpress.org/Content_Visibility' ) . '</mark>';
$error = true;
} else {
// Shortcode check

View File

@ -11,7 +11,7 @@ if ( ! defined( 'ABSPATH' ) ) {
<div id="message" class="updated woocommerce-message wc-connect">
<a class="woocommerce-message-close notice-dismiss" href="<?php echo esc_url( wp_nonce_url( add_query_arg( 'wc-hide-notice', 'theme_support' ), 'woocommerce_hide_notices_nonce', '_wc_notice_nonce' ) ); ?>"><?php _e( 'Dismiss', 'woocommerce' ); ?></a>
<p><?php printf( __( '<strong>Your theme does not declare WooCommerce support</strong> &#8211; Please read our %1$sintegration%2$s guide or check out our %3$sStorefront%4$s theme which is totally free to download and designed specifically for use with WooCommerce.', 'woocommerce' ), '<a target="_blank" href="' . esc_url( apply_filters( 'woocommerce_docs_url', 'https://docs.woocommerce.com/document/third-party-custom-theme-compatibility/', 'theme-compatibility' ) ) . '">', '</a>', '<a target="_blank" href="' . esc_url( admin_url( 'theme-install.php?theme=storefront' ) ) . '">', '</a>' ); ?></p>
<p><?php printf( __( '<strong>Your theme does not declare WooCommerce support</strong> &#8211; Please read our <a href="%1$s" target="_blank">integration</a> guide or check out our <a href="%2$s" target="_blank">Storefront</a> theme which is totally free to download and designed specifically for use with WooCommerce.', 'woocommerce' ), esc_url( apply_filters( 'woocommerce_docs_url', 'https://docs.woocommerce.com/document/third-party-custom-theme-compatibility/', 'theme-compatibility' ) ), esc_url( admin_url( 'theme-install.php?theme=storefront' ) ) ); ?></p>
<p class="submit">
<a href="https://woocommerce.com/storefront/?utm_source=notice&amp;utm_medium=product&amp;utm_content=storefront&amp;utm_campaign=woocommerceplugin" class="button-primary" target="_blank"><?php _e( 'Read more about Storefront', 'woocommerce' ); ?></a>
<a href="<?php echo esc_url( apply_filters( 'woocommerce_docs_url', 'http://docs.woocommerce.com/document/third-party-custom-theme-compatibility/?utm_source=notice&utm_medium=product&utm_content=themecompatibility&utm_campaign=woocommerceplugin' ) ); ?>" class="button-secondary" target="_blank"><?php _e( 'Theme integration guide', 'woocommerce' ); ?></a>

View File

@ -103,10 +103,13 @@ class WC_Emails {
/**
* Init the mailer instance and call the notifications for the current filter.
*
* @internal param array $args (default: array())
* @internal
*
* @param string $filter Filter name.
* @param array $args Email args (default: []).
*/
public static function send_queued_transactional_email( $filter = '', $args = array() ) {
if ( apply_filters( 'woocommerce_send_queued_transactional_email', true, $filter, $args ) ) {
if ( apply_filters( 'woocommerce_allow_send_queued_transactional_email', true, $filter, $args ) ) {
self::instance(); // Init self so emails exist.
do_action_ref_array( $filter . '_notification', $args );
}
@ -115,7 +118,9 @@ class WC_Emails {
/**
* Init the mailer instance and call the notifications for the current filter.
*
* @internal param array $args (default: array())
* @internal
*
* @param array $args Email args (default: []).
*/
public static function send_transactional_email( $args = array() ) {
$args = func_get_args();