William
Forum Replies Created
-
After contacting support for the GDPR plugin I have a potential workaround for those with a similar problem. If you are using the GDPR Cookie Consent plugin, this script will prevent the script blocker working on a specific page (in my case the transaction page) for cookies of a given category.
add_action('wp_head', 'wt_cli_auto_accept_on_page'); function wt_cli_auto_accept_on_page() { if (class_exists('Cookie_Law_Info')) { ?> <script> var autoAcceptUrl = '/PAGEURL/'; //URL/slug pattern for auto accepting category var autoAcceptCategory = 'COOKIECATEGORY'; //slug name of the Google Tag Manager's category if (window.location.href.indexOf(autoAcceptUrl) > -1) { $("script[data-cli-script-type='"+autoAcceptCategory+"']").each( function() { $(this).attr('data-cli-block', 'false'); }); } </script> <?php } }Hi Matheus, unfortunately it does not seem like this will help my situation, and may not in future. The issue is simply that blocking Google Tag manger scripts prevents transaction from completing. This is the issue.
IF you know of a workaround for this conflict please let me know.
Forum: Developing with WordPress
In reply to: Custom Dynamic Sidebar Not Displaying in Widget AreaGood call, @bcworkz. There was indeed a return function in the code above that was causing the issue. Commenting and then removing it resolved the issue.
Thank you.
Forum: Developing with WordPress
In reply to: Custom Dynamic Sidebar Not Displaying in Widget AreaI have done some testing and this is definitely an issue with the child-theme’s functions. Even though I have my child-theme styles enqueued, the functions in the same functions.php file do not run.
Even changing the priority does not help.
Any suggestions on where to find an override?
Forum: Developing with WordPress
In reply to: Custom Dynamic Sidebar Not Displaying in Widget AreaHi @bcworkz, this is my assumption as well. I’ve made sure to clear browser cache as well as my my WordPress’s Autoptimise and W3 Total Cache plugin’s and CDN.
Even after 24 hours, the sidebar does not appear in my Admin Widgets area. I can’t think of where else it could be caching.
- This reply was modified 5 years, 6 months ago by William.