Hot answers tagged

2

Ok I found out the solution. Because, as I said, WooCommerce has it's own hooks, first of all I've searched for a WooCommerce hook about registration. I discovered the existence of a hook very similiar to the one used by WordPress: woocommerce_registration_errors. Obviously it works in the same way. Then I simply replaced the WordPress hook with the ...


2

Sorry I can not comment yet on this site Could you be removing an action before it is registered? Have you tried wrapping this with an on init hook? Perhaps using remove_filter would be a better choice. function my_init() { remove_filter( 'storefront_header', array( 'Galleria_Structure', 'galleria_top_bar_wrapper' ) ); remove_filter( ...


2

You can do in the following way! Create an array of CSS class names and message values $colors_stings = array( 'Message one' => 'message_color_green', 'Message two' => 'message_color_red', 'Message three' => 'message_color_blue' ); Check if message string exist in array then assign CSS color class to variable. $css_class = ...


2

As the keys already hold PHP generated output, it should be possible to simply wrap them in some MarkUp woocommerce_wp_select( array( 'id' => 'productstatus_select', 'label' => __( 'Product Status', 'woocommerce' ), 'options' => array( 'Message one' => sprintf( '<span ...



Only top voted, non community-wiki answers of a minimum length are eligible