warezio
Forum Replies Created
-
Never mind, it is not a problem.
I put wc_print_notices() into the shortcode template, but it supposed not to be inside of shortcode.
I closed this case.Sorry, I was just in hurry. I cannot say this is an error.
I’m using woocommerce plugin and there is a function that wc_print_notices().
When some event action, wc_print_notices() shows a message about error, success, etc.But, since I installed All in One SEO Pack, wc_print_notices() not shows any messages.
The page ‘edit-password’ is one of woocommerce shortcord template that user can change their password, if user enter something wrong data, it should show an error message.I traced source about wc_print_notices(), and I found some thing that makes wc_print_notices() called twice so the wc_clear_notices() called in wc_print_notice() that is why the message not shows up.
I got some part of All in One SEO Pack which is below,/wp-content/plugins/all-in-one-seo-pack/aioseop_class.php line: 2562
function get_post_description( $post ) { //... $content = do_shortcode( $content ); //...
* Page conditionals
is_page() && is_singular() && is_object( $post ) && ! is_archive() && empty( $blog_page )when I just edited to // $content = do_shortcode( $content ); then wc_print_notices() message appears normally.
I’m not sure yet how relative between them, but I guess there are some sort of relation with do_shortcode(). If there were some filters, would be avoid “Not showing message” when on any empty description page.What do you think is the best way to show wc_print_notices() message in shortcode page without description?