{"id":4557,"date":"2022-04-04T21:07:55","date_gmt":"2022-04-04T18:07:55","guid":{"rendered":"https:\/\/creativethemes.com\/blocksy\/?post_type=documentation&#038;p=4557"},"modified":"2026-10-09T20:24:03","modified_gmt":"2026-10-09T17:24:03","slug":"restore-built-in-woocommerce-product-gallery","status":"publish","type":"documentation","link":"https:\/\/creativethemes.com\/blocksy\/docs\/code-snippets\/restore-built-in-woocommerce-product-gallery\/","title":{"rendered":"Restore built-in WooCommerce product gallery"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Blocksy employs a very nice product gallery, which can be customised further using the Customiser. If you wish to return to WooCommerce&#8217;s default gallery for whatever reason, feel free to use the snippet below.<\/p>\n\n\n<div class=\"ct-code-box wp-block-blocksy-landing-child-code-box\" data-type=\"php\">\n\t<div class=\"ct-code-box__header\">\n\t\t<div class=\"ct-code-box__meta\">\n\t\t\t<span class=\"ct-code-box__label\"><svg viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" aria-hidden=\"true\"><path d=\"m9 8-4 4 4 4\"\/><path d=\"m15 8 4 4-4 4\"\/><\/svg>PHP<\/span>\n\t\t\t\t\t\t\t<span class=\"ct-code-box__title\">Use WooCommerce built in gallery<\/span>\n\t\t\t\t\t<\/div>\n\t\t<button type=\"button\" class=\"ct-code-box__copy\" aria-label=\"Copy code\">\n\t\t\t<svg class=\"ct-code-box__icon-copy\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" stroke-linejoin=\"round\" aria-hidden=\"true\"><rect x=\"9\" y=\"9\" width=\"11\" height=\"11\" rx=\"2\"\/><path d=\"M5 15V6a2 2 0 0 1 2-2h9\"\/><\/svg>\n\t\t\t<svg class=\"ct-code-box__icon-check\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2.2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" aria-hidden=\"true\"><path d=\"M5 12.5l4.5 4.5L19 7.5\"\/><\/svg>\n\t\t\t<span class=\"ct-code-box__copy-label\">Copy<\/span>\n\t\t<\/button>\n\t<\/div>\n\t<pre class=\"ct-code-box__code\"><code>add_filter(&#039;blocksy:woocommerce:product-view:use-default&#039;, function ($current_value) {\n  return true;\n});<\/code><\/pre>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Blocksy employs a very nice product gallery, which can be customised further using the Customiser. If you wish to return to WooCommerce&#8217;s default gallery for whatever reason, feel free to use the snippet below.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","template":"","meta":{"_acf_changed":false,"footnotes":""},"doc_categories":[125],"class_list":["post-4557","documentation","type-documentation","status-publish","hentry","doc_categories-code-snippets"],"acf":[],"_links":{"self":[{"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/documentation\/4557","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/documentation"}],"about":[{"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/types\/documentation"}],"author":[{"embeddable":true,"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/comments?post=4557"}],"version-history":[{"count":2,"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/documentation\/4557\/revisions"}],"predecessor-version":[{"id":15385,"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/documentation\/4557\/revisions\/15385"}],"wp:attachment":[{"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/media?parent=4557"}],"wp:term":[{"taxonomy":"doc_categories","embeddable":true,"href":"https:\/\/creativethemes.com\/blocksy\/wp-json\/wp\/v2\/doc_categories?post=4557"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}