woocommerce_page_wc-addons_connection_error
woocommerce_page_wc-addons_connection_error
Appears in: woocommerce.6.3.1, woocommerce.6.4.1, woocommerce.6.5.1, woocommerce.6.6.1, woocommerce.6.7.0, woocommerce.6.8.0, woocommerce.6.8.1, woocommerce.6.8.2, woocommerce.6.9.0, woocommerce.6.9.4, woocommerce.7.0.0, woocommerce.7.1.0, woocommerce.7.1.1, woocommerce.7.2.2, woocommerce.7.3.0, woocommerce.7.4.0, woocommerce.7.4.1, woocommerce.7.5.1, woocommerce.7.6.0, woocommerce.7.6.1, woocommerce.7.7.0, woocommerce.7.7.1, woocommerce.7.8.1, woocommerce.7.9.0, woocommerce.8.0.3, woocommerce.8.1.1, woocommerce.8.2.1, woocommerce.8.2.2, woocommerce.8.3.1, woocommerce.8.4.0, woocommerce.8.5.1, woocommerce.8.5.2, woocommerce.8.6.0, woocommerce.8.6.1, woocommerce.8.7.0, woocommerce.8.8.3, woocommerce.8.9.2, woocommerce.8.9.3, woocommerce.9.0.2, woocommerce.9.1.2, woocommerce.9.1.4, woocommerce.9.2.2, woocommerce.9.2.3, woocommerce.9.3.1, woocommerce.9.3.3, woocommerce.9.4.2, woocommerce.9.4.3, woocommerce.9.5.1
Hook Type: action
See hook in action
Displaying hooks found in version: woocommerce.9.5.1do_action('woocommerce_page_wc-addons_connection_error') is found 6 times:
- /includes/admin/class-wc-admin-addons.php line 43
); $raw_featured = self::fetch( $url, $fetch_options ); if ( is_wp_error( $raw_featured ) ) { do_action( 'woocommerce_page_wc-addons_connection_error', $raw_featured->get_error_message() ); $message = self::is_ssl_error( $raw_featured->get_error_message() ) ? __( 'We encountered an SSL error. Please ensure your site supports TLS version 1.2 or above.', 'woocommerce' ) : $raw_featured->get_error_message(); return new WP_Error( 'wc-addons-connection-error', $message );
- /includes/admin/class-wc-admin-addons.php line 54
} $response_code = (int) wp_remote_retrieve_response_code( $raw_featured ); if ( 200 !== $response_code ) { do_action( 'woocommerce_page_wc-addons_connection_error', $response_code ); /* translators: %d: HTTP error code. */ $message = sprintf( esc_html( /* translators: Error code */ __(
- /includes/admin/class-wc-admin-addons.php line 73
} $featured = json_decode( wp_remote_retrieve_body( $raw_featured ) ); if ( empty( $featured ) || ! is_array( $featured ) ) { do_action( 'woocommerce_page_wc-addons_connection_error', 'Empty or malformed response' ); $message = __( 'Our request to the featured API got a malformed response.', 'woocommerce' ); return new WP_Error( 'wc-addons-connection-error', $message ); } if ( $featured ) {
- /includes/admin/class-wc-admin-marketplace-promotions.php line 154
* Allows connection error to be handled. * * @since 8.7 */ do_action( 'woocommerce_page_wc-addons_connection_error', $raw_promotions->get_error_message() ); } $response_code = (int) wp_remote_retrieve_response_code( $raw_promotions ); if ( 200 !== $response_code ) { /** * Allows connection error to be handled.
- /includes/admin/class-wc-admin-marketplace-promotions.php line 164
* Allows connection error to be handled. * * @since 8.7 */ do_action( 'woocommerce_page_wc-addons_connection_error', $response_code ); } $promotions = json_decode( wp_remote_retrieve_body( $raw_promotions ), true ); if ( ! is_array( $promotions ) ) { $promotions = array();
- /includes/admin/class-wc-admin-marketplace-promotions.php line 177
* Allows connection error to be handled. * * @since 8.7 */ do_action( 'woocommerce_page_wc-addons_connection_error', 'Malformed response' ); } // phpcs:enable WordPress.NamingConventions.ValidHookName.UseUnderscores return $promotions; }