• Resolved fair44

    (@fair44)


    Hello,
    I’m afraid to understand.
    The visitor must manually enabled cookies for scripts to be integrated?
    Is it not possible to enable by default. Without this, no visitor will activate.
    thank you,

    The page I need help with: [log in to see the link]

Viewing 15 replies - 1 through 15 (of 15 total)
  • I would need some cookies other then strictly necessary cookies to be enabled by default. Would be awesome if you could figure out a way to do so.

    Thread Starter fair44

    (@fair44)

    I don’t understand…

    MA

    (@gasparnemes)

    Hi there,

    To enable the cookies by default you can add the following scripts to your theme’s functions.php, and align the code:

    function gdpr_js_extension() {
        ob_start();
        ?>
        <script>
        	jQuery(document).ready(function(){
        		if ( ! document.cookie.match(/^(.*;)?\s*moove_gdpr_popup\s*=\s*[^;]+(.*)?$/) ) {
    				jQuery(this).moove_gdpr_save_cookie({
    					thirdParty: true,
    					advanced: true,
    					scrollEnable: 200
    				});
        		}
        	});
        </script>
        <?php
        echo ob_get_clean();
    }
    add_action( 'wp_footer', 'gdpr_js_extension', 1000 );

    I hope this works.

    Hi Gaspar,
    I added this code snippet to the function.php, but that don’t work for me.
    Any solution?

    MA

    (@gasparnemes)

    Hi @ria_,

    Could you please try this one?

    function moove_gdpr_script_extension() {
       	wp_add_inline_script(
    	   	"moove_gdpr_frontend",
    	   	"jQuery(document).ready(function(){
    			jQuery(this).moove_gdpr_save_cookie({
    				thirdParty: true,
    				advanced: true,
    				scrollEnable: 200
    			});
    		});",
    		"after"
    	);
    }
    add_action( 'wp_enqueue_scripts', 'moove_gdpr_script_extension', 999 );

    I hope it works..

    Hi there, awesome plugin, but I have the same problems, no one of this solutions seems to work for me. Is there a way to enable the single cookie by default on the plugin settings section?
    pratically i’m askyng you make a modification on the plugin, I know, but this would solve the problem w/o making me change the code, YOUR code.
    Anyway this workarounds doesnt’ work for me =(

    Hi Gaspar,
    The first code snippet works in an another site where I tried.
    But as I see that change the value of cookie when I scrolled the page, it’s weird a bit.
    And I see the status ‘Enabled’ in the popup, but my script is not in the header ??
    That would be really great if you could add this feature to the plugin. I mean that the enabled could be the default settings.
    Léci-léci ??

    MA

    (@gasparnemes)

    Hello,

    Could you please confirm you’re using the latest version of the plugin?

    Also, if it’s possible please provide me a link to your site to check how it works on your end.

    Thanks

    last version of everything.
    https://potature.roma.it/

    ok on local machine I’ve make different test on your second snippet. it work only after first usage, basically I have to open the popup, close it NOT by the big X or che accept button but clicking somewhere else on the page, then reopen the setting page and just now my checkboxs are green. but as @ria_ was saying, the code is not running.

    MA

    (@gasparnemes)

    Hi both,

    Could you please confirm you’ve purged all the caches on your server after added the code snippet to your theme?
    I’ve checked the source code and doesn’t contains the following code snippet.

    Gaspar

    all cleared

    MA

    (@gasparnemes)

    Hello,

    Thanks for the confirmation.

    I will try to implement this feature into the plugin in a future release, added as a feature request.

    In the meanwhile, you can try to add the first code snippet from this thread, and purge all the caches, after once you go to view-source of your page, and find for the key “moove_gdpr_save_cookie” you should find the snippet. Currently this is missing, and that’s why it doesn’t work.

    Thanks

    unbelievable I can’t find it online, I’ve purged everithing. I’ll try to test on another site. on local I find the snippet, but my code insn’t there. no green checkbox, no cookie code =(

    I’ll wait for your new release, thanks so mutch, excellent work

    Hi there,

    Really great plugin guys, fantastic work.

    We’ve implemented the first code in this thread and it works perfectly.

    However, the cookie notice at the foot of the page disappears upon page refresh, is there a way to keep the notice showing until someone physically clicks the “accepts cookies” button.

    Ideally we would like third party cookies to be Enabled by default (which they are with the script above), but the visitor would need to click “Accept” in order to remove the footer message.

    Any help would be hugely appreciated.

    Thanks

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘Default cookies activation’ is closed to new replies.