Tagged: x
-
AuthorPosts
-
July 21, 2016 at 3:33 pm #1097605
rotipomParticipantI’m trying to understand if I can insert an Accordion Shortcode that is already pre-filled with my desired content (in this case FAQ) anywhere I like?
I manage to insert it into Woocommerce Product Page but I don’t want to have to type a new one for each product. I want to just add the shortcode and all the FAQ content is pulled up?
http://www.amytwon.com/product/labyrinth-expedition-kit/
July 21, 2016 at 4:04 pm #1097668
rotipomParticipantI managed to add the shortcode using a roundabout method -create the accordion FAQ block in a regular page using cornerstone, and then copy the code and paste it in woocommerce single product page.
http://www.amytwon.com/product/labyrinth-expedition-kit/
This means that I’m having to copy and paste the full code for each product. Is there a way to reference that accordian block using shortcode without individually pasting the full code in every product page?
July 21, 2016 at 9:05 pm #1098061
FriechModeratorHi There,
Thanks for writing in! You can add this on your child theme’s functions.php file.
add_action( 'woocommerce_before_add_to_cart_form', 'add_to_single_product_summary' ); function add_to_single_product_summary() { echo do_shortcode( ' /*REPLACE THIS WITH YOUR SHORTCODE*/ ' ); }Hope it helps, Cheers!
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-1097605 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
