{"id":2145,"date":"2021-01-15T14:25:57","date_gmt":"2021-01-15T14:25:57","guid":{"rendered":"https:\/\/grooni.com\/docs\/groovy-menu\/?page_id=2145"},"modified":"2021-01-15T14:25:57","modified_gmt":"2021-01-15T14:25:57","slug":"pro-theme-by-themeco","status":"publish","type":"page","link":"https:\/\/grooni.com\/docs\/groovy-menu\/theme-integration\/pro-theme-by-themeco\/","title":{"rendered":"Pro theme by Themeco"},"content":{"rendered":"<p>Add this code into <code>function.php<\/code> of your <a href=\"https:\/\/developer.wordpress.org\/themes\/advanced-topics\/child-themes\/\">child theme<\/a>.<\/p>\n<blockquote>\n<p>Please make all changes to the child theme files, and do not add the code directly to the theme files, otherwise after updating the theme your fixes will be lost<\/p>\n<\/blockquote>\n<p><code>function.php<\/code><\/p>\n<pre><code>if ( ! function_exists( 'gm_custom_pro_child_theme_integration' ) ) {\n\t\/\/ Add Groovy Menu integration function.\n\tadd_action( 'wp_body_open', 'gm_custom_pro_child_theme_integration', 5 );\n\n\tfunction gm_custom_pro_child_theme_integration() {\n\t\tif ( function_exists( 'groovy_menu' ) ) {\n\n\t\t\tadd_action( 'x_after_site_begin', 'gm_custom_pro_child_theme_integration__start_cache', 0 );\n\t\t\tadd_action( 'x_after_view_header_base', 'gm_custom_pro_child_theme_integration__clear_cache', 99999 );\n\n\t\t\tgroovy_menu();\n\t\t}\n\t}\n\n\tif ( ! function_exists( 'gm_custom_pro_child_theme_integration__start_cache' ) ) {\n\t\tfunction gm_custom_pro_child_theme_integration__start_cache() {\n\t\t\tob_start();\n\t\t}\n\t}\n\n\tif ( ! function_exists( 'gm_custom_pro_child_theme_integration__clear_cache' ) ) {\n\t\tfunction gm_custom_pro_child_theme_integration__clear_cache() {\n\t\t\t$cleared_html = ob_get_clean();\n\t\t\tunset( $cleared_html );\n\t\t}\n\t}\n\n}\n<\/code><\/pre>\n\n\n<div style=\"height:20px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n<div class=\"alert alert-warning\"><strong>Note:<\/strong> You can find the child theme for the PRO Theme in the <code>Groovy Menu &gt; Integration section<\/code><\/div>","protected":false},"excerpt":{"rendered":"<p>Add this code into function.php of your child theme. Please make all changes to the child theme files, and do &hellip; <a href=\"https:\/\/grooni.com\/docs\/groovy-menu\/theme-integration\/pro-theme-by-themeco\/\">Read more &rarr;<\/a><\/p>\n","protected":false},"author":3,"featured_media":0,"parent":2075,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":[],"_links":{"self":[{"href":"https:\/\/grooni.com\/docs\/groovy-menu\/wp-json\/wp\/v2\/pages\/2145"}],"collection":[{"href":"https:\/\/grooni.com\/docs\/groovy-menu\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/grooni.com\/docs\/groovy-menu\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/grooni.com\/docs\/groovy-menu\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/grooni.com\/docs\/groovy-menu\/wp-json\/wp\/v2\/comments?post=2145"}],"version-history":[{"count":0,"href":"https:\/\/grooni.com\/docs\/groovy-menu\/wp-json\/wp\/v2\/pages\/2145\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/grooni.com\/docs\/groovy-menu\/wp-json\/wp\/v2\/pages\/2075"}],"wp:attachment":[{"href":"https:\/\/grooni.com\/docs\/groovy-menu\/wp-json\/wp\/v2\/media?parent=2145"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}