Activate Borlabs Cookie Meta Box
To activate the Meta Box in a post type, check the corresponding post type under Settings > Display Meta Box. If you want to use the meta box in pages, check the box for pages and if you want to use it in posts, for posts etc.
For example, if you want to run code from Google Analytics on a particular page only after the visitor has agreed to the Google Analytics Cookie, go to Cookies > Statistics and open the Google Analytics Cookie settings.
Now copy the Shortcode for Google Analytics under Cookie Settings.
Go to the page where you want to execute your code. Scroll down and copy the Borlabs Cookie Shortcode into the meta box. Now you have to replace …block this… with the code you want to use (in our example Google Analytics).
In our example it looks like this:
Now the code is only executed when your visitor has agreed to the Google Analytics Cookie in the Cookie Box.