1 Reply Latest reply on Sep 14, 2015 2:36 PM by diego.medrano

    get Mouse click coordinate on embedded view

    Nachiket Kare

      Hey,

       

      I'm working with Tableau Online.

      I have a view which I have embedded in my website.Now whenever the uses click on the viz, I want to

      know the mouse coordinate of the click. Is there any way to implement this functionality.

      This is my code.

      var iframes = document.getElementsByTagName("iframe");

        onlyIframe = iframes[0];

        var range = onlyIframe.contentWindow;

        range.onclick = function(e){

        alert(e.clientX + " " + e.clientY);

        }

       

      My application is hosted on the Tomcat server. I get a security error from the tableau server. This is the error: ' Protocols, domains, and ports must match.'

      How do I solve this?

        • 1. Re: get Mouse click coordinate on embedded view

          Hey Nachiket,

           

          I don't know of any easy way to get this data. My best guess says there is probably a hacky way to do it but that's not my forte. Perhaps, if you used a service like CrazyEgg you could see a heat map of the site that has the visualization so you can see where users click. I don't have experience to know if CrazyEgg will work on our visualizations.