-
AuthorPosts
-
January 8, 2016 at 7:19 pm #562173
Everything seems to be fine apart from the styling on the online shop product page.
As you can see from the attached link the product images are now full width which is not right.
I remember using a recommendation by the Enfold support staff to hack in a sidebar on the right side of product pages (the fact this has to be done is a joke btw). So I think the CSS has broken with the updates.
Any help is very much appreciated.
Luke
January 9, 2016 at 9:01 am #562375Hi Luke86,
Please send us a temporary admin login so that we can have a closer look. You can post the details in the Private Content section of your reply.
Best regards,
RikardJanuary 11, 2016 at 12:03 pm #563051see private data.
January 12, 2016 at 9:30 am #563759Hi!
I’m sorry but the theme doesn’t support conventional sidebars for the single product pages. The ‘hack” is required and it has been updated. Please try to replace the code in the functions.php file:
# # wrap single product image in an extra div # function avia_add_image_div() { echo "<div class='single-product-main-image alpha'>"; } function avia_close_image_div() { echo "</div>"; } # # wrap single product summary in an extra div # function avia_add_summary_div() { echo "<div class='single-product-summary'>"; } function avia_close_summary_div() { global $avia_config; echo "</div>"; //close out the summary $avia_config['currently_viewing'] = "shop_single"; get_sidebar(); } function avf_product_sidebar_layout_mod($layout){ if( is_single() )$layout = "sidebar_left"; return $layout; } add_action('init', 'ava_product_sidebar_mod'); function ava_product_sidebar_mod() { add_action( 'woocommerce_before_single_product_summary', 'avia_add_image_div', 2 ); add_action( 'woocommerce_before_single_product_summary', 'avia_close_image_div', 20 ); add_action( 'woocommerce_before_single_product_summary', 'avia_add_summary_div', 25 ); add_action( 'woocommerce_after_single_product_summary', 'avia_close_summary_div', 3 ); add_filter( 'avf_product_sidebar_layout', 'avf_product_sidebar_layout_mod', 5); }
Edit config-woocommerce > config.php file, look for this code:
$sidebar_setting = avia_layout_class( 'main' , false );
Replace it with:
$sidebar_setting = apply_filters( 'avf_product_sidebar_layout', avia_layout_class( 'main' , false ) );
Add this to the Quick CSS field:
.single-product .product { width: 68%; margin-right: 4%; clear: none; float: left; }
Regards,
IsmaelJanuary 14, 2016 at 4:51 pm #565532Works, thank you!
-
AuthorPosts
- The topic ‘Updated Enfold & WordPress & Woocommerce’ is closed to new replies.