GithubHelp home page GithubHelp logo

Comments (15)

darrenlma avatar darrenlma commented on September 3, 2024

We too had this issue and not entirely sure of the cause but our workspace had multiple website sources. Removing all but one had the Consent Manager working as intended.

If this is also the case with your issues, have you any idea why this may be? Or how it could be fixed?

from consent-manager.

Nbennett650 avatar Nbennett650 commented on September 3, 2024

Did you figure this out?

from consent-manager.

marceldegraaf avatar marceldegraaf commented on September 3, 2024

Nope, we ended up rolling our own cookie bar implementation because we ran into too much trouble with the Segment one.

from consent-manager.

Uysim avatar Uysim commented on September 3, 2024

Anyone has this fixed? I got the same problem

from consent-manager.

darrenlma avatar darrenlma commented on September 3, 2024

For us it seemed that we could only have a single source and it had to contain a destination. I assume that without these, the consent bar had no reason to display as no destinations were using cookies or implemented script into the browser.

from consent-manager.

Uysim avatar Uysim commented on September 3, 2024

@discovrbookings I try to add source from javascript and destination to slack. But no matter what it is not showing anything

from consent-manager.

darrenlma avatar darrenlma commented on September 3, 2024

@Uysim Are you receiving events in the debug of the source? Also, does the Segment script show up in your <head>. We did find that it wasn't immediately available and coming back later it was there. Also, clear your cookies in browser. This may jolt the consent manager to work.

from consent-manager.

Uysim avatar Uysim commented on September 3, 2024
<style type="text/css">
  #consent-container {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 100;
  }
</style>
<div id="consent-container"></div>


<!-- footer --->
<script>
  !function(){var analytics=window.analytics=window.analytics||[];if(!analytics.initialize)if(analytics.invoked)window.console&&console.error&&console.error("Segment snippet included twice.");else{analytics.invoked=!0;analytics.methods=["trackSubmit","trackClick","trackLink","trackForm","pageview","identify","reset","group","track","ready","alias","debug","page","once","off","on"];analytics.factory=function(t){return function(){var e=Array.prototype.slice.call(arguments);e.unshift(t);analytics.push(e);return analytics}};for(var t=0;t<analytics.methods.length;t++){var e=analytics.methods[t];analytics[e]=analytics.factory(e)}analytics.load=function(t,e){var n=document.createElement("script");n.type="text/javascript";n.async=!0;n.src="https://cdn.segment.com/analytics.js/v1/"+t+"/analytics.min.js";var a=document.getElementsByTagName("script")[0];a.parentNode.insertBefore(n,a);analytics._loadOptions=e};analytics.SNIPPET_VERSION="4.1.0";
  analytics.load("WRITE_KEY");
  analytics.page();
  }}();
</script>
<script
  src="https://unpkg.com/@segment/[email protected]/standalone/consent-manager.js"
  crossorigin="anonymous"
  defer
  data-container="#consent-container"
  data-writeKey="WRITE_KEY"
  data-bannerContent="We use cookies (and other similar technologies) to collect data to improve your experience on our site."
  data-bannerSubContent="You can change your preferences at any time."
  data-preferencesDialogTitle="Website Data Collection Preferences"
  data-preferencesDialogContent="We use data collected by cookies and JavaScript libraries to improve your browsing experience, analyze site traffic, deliver personalized advertisements, and increase the overall performance of our site."
  data-cancelDialogTitle="Are you sure you want to cancel?"
  data-cancelDialogContent="Your preferences have not been saved. By continuing to use our website, you՚re agreeing to our Website Data Collection Policy."
></script>

@discovrbookings above is my code. I use private browser so there is no cookies but It still not show anything inside consent-container it created an empty div

from consent-manager.

darrenlma avatar darrenlma commented on September 3, 2024

You do need to remove analytics.load("YOUR_WRITE_KEY"); from your script as this is injected by the consent manager component.

from consent-manager.

darrenlma avatar darrenlma commented on September 3, 2024

@Uysim or is your code, already compiled? and that is the HTML source?

from consent-manager.

Uysim avatar Uysim commented on September 3, 2024

@discovrbookings what do you mean compiled? that is the html code.

from consent-manager.

darrenlma avatar darrenlma commented on September 3, 2024

@Uysim I meant are you using Angular, React, etc and your code is static content in your public folder or is it the HTML source from the browser?

from consent-manager.

Uysim avatar Uysim commented on September 3, 2024

@discovrbookings thank for you help. But my problem fix after mailing with support and he ask me to wait 5 or 10 minutes.

from consent-manager.

rpholdaway avatar rpholdaway commented on September 3, 2024

It was fixed in my case by adding a destination to the source (then waiting about 90 mins for it to take effect).

from consent-manager.

felipe-najson-ntf avatar felipe-najson-ntf commented on September 3, 2024

Hi everyone, sorry for the late reply. The standalone version is working correctly in the current version of consent manager, the documentation has been updated also for a clearer installation.
Here I leave a link.
https://github.com/segmentio/consent-manager#standalone-script

If you continue to have problems feel free to open another issue. On the other hand, I will close this issue since it was resolved.

Segment team.

from consent-manager.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.