Forum Replies Created

Viewing 6 replies - 31 through 36 (of 36 total)
  • @andreagilfone

    Yes, for now you do need to repeat the code.
    I dont know why, but my has_consent does not work, I only use the is_allowed cookie.

    function my_google_opt_out() {
        if ( is_allowed_cookie( '_ga' ) ) {
    ?>
            <script>
    		window['ga-disable-UA-xxxx-x'] = false;
    	</script>
    	
    	<?php
                                           }
    	else{
    ?>
    	<script>
    		window['ga-disable-UA-xxxx-x'] = true;
    	</script>
    <?php
                 }
                                   }

    This is my code, maybe this helps you. Let me know!

    • This reply was modified 6 years, 9 months ago by Willem Munts.
    • This reply was modified 6 years, 9 months ago by Willem Munts.
    • This reply was modified 6 years, 9 months ago by Willem Munts.
    • This reply was modified 6 years, 9 months ago by Willem Munts.
    • This reply was modified 6 years, 9 months ago by Willem Munts.
    Forum: Plugins
    In reply to: [GDPR] Wildcard cookies

    You could maybe create a category with PUPcOOK- .
    You have to type it once, then have one toggle button for all the PUPcOOK- ‘s right?
    I think this is best option for now.

    If you want to check were they are working on at the moment or what will come:
    https://github.com/trewknowledge/GDPR/projects/1?fullscreen=true

    Goodluck

    • This reply was modified 6 years, 9 months ago by Willem Munts.

    @mic85b

    I’m sorry but that is not useful at all. The code itself is not useful at all, because it will not work on every website. I have tried a lot of times to adjust the code. Now after almost 2weeks i have the correct code. And its ok to have an example of GA, but other cookies are twice as hard to find the correct code to disable them.

    @triplecomp
    If you do not want the cookie to work before accepting the privacy bar you should try the following that i am using(i am using google analytics as example in this one:

    function my_google_opt_out() {
        if ( is_allowed_cookie( '_ga' ) ) {
        ?>
        <script>
    		window['ga-disable-UA-xxxx-xx'] = false;
    	</script>
    	
    	<?php
      }
    	else{
    ?>
    	<script>
    		window['ga-disable-UA-xxxx-x'] = true;
    	</script>
    <?php
    }
    }

    This means, if the cookie is allowed, the cookie GA disable is FALSE, so will be active.
    If the cookie is not allowed(else) and you have the category with the cookie you want standard on OFF, then the cookie is not allowed and it will activate the else. The GA disabled will be set to true and so, it will be disabled.

    p.s. dont forget to replace the XXXX by your GA ID, ofcourse for other cookie this is not needed. Also make sure that you search the cookies, and insert them inside the category like following: _ga,_gid,_PHPSESSID,_ss . So with comma’s between but no spaces.

    This worked for me, if it doesnt for you, you should adjust the code a bit to your website.
    Goodluck!

    • This reply was modified 6 years, 9 months ago by Willem Munts.
    • This reply was modified 6 years, 9 months ago by Willem Munts.
    Forum: Plugins
    In reply to: [GDPR] Activate cookies
    Thread Starter Willem Munts

    (@thedarkeye)

    @fclaussen

    Its not very clear, for example i have smartlook cookie. So at a certain point you say window _ga … … But how do i know how to do that for another cookie?

    Grtz Willem

    Willem Munts

    (@thedarkeye)

    Hello,

    I think it has to do with the % VAT that is being proccessed.
    I had this problem before and it when i did some research the most logic explanation was that if you change it to dollars or euros, for example it will be $6.11, then it will not be a normal % VAT for your administration. This is what i could make out of it, hope this is usefull for you, otherwise goodluck!

    Cheers

Viewing 6 replies - 31 through 36 (of 36 total)