3 Replies Latest reply on Nov 30, 2016 9:21 AM by John Barr

    Problem with embed code

    Sophia Messini

      Hello everybody!

      I am facing a problem with embed codes and I want to ask you for help. I have create some maps in tableau public and when I copy the embed code to my web site the maps are not interactive as they are in tableau. Could you tell me what I am doing wrong?


      Here you can see my maps Tableau Public  and here my web ΕΚΛΟΓΕΣ 2007 | DATA JOURNALISM


      Thank you in advance


        • 1. Re: Problem with embed code

          Hi Sophia,


          Apart from coping that link use the embed code, it will work.


          For you I am pasting your dashboard map code below, please check and let me know if you are getting error.


          I have tested from my side and it's working.


          <div class='tableauPlaceholder' id='viz1476081365889' style='position: relative'><noscript><a href='#'><img alt='Dashboard 1 ' src='https:&#47;&#47;public.tableau.com&#47;static&#47;images&#47;20&#47;2007_10&#47;Dashboard1&#47;1_rss.png' style='border: none' /></a></noscript><object class='tableauViz'  style='display:none;'><param name='host_url' value='https%3A%2F%2Fpublic.tableau.com%2F' /> <param name='site_root' value='' /><param name='name' value='2007_10&#47;Dashboard1' /><param name='tabs' value='no' /><param name='toolbar' value='yes' /><param name='static_image' value='https:&#47;&#47;public.tableau.com&#47;static&#47;images&#47;20&#47;2007_10&#47;Dashboard1&#47;1.png' /> <param name='animate_transition' value='yes' /><param name='display_static_image' value='yes' /><param name='display_spinner' value='yes' /><param name='display_overlay' value='yes' /><param name='display_count' value='yes' /></object></div>                <script type='text/javascript'>                    var divElement = document.getElementById('viz1476081365889');                    var vizElement = divElement.getElementsByTagName('object')[0];                    if ( divElement.offsetWidth > 800 ) { vizElement.style.width='100%';vizElement.style.height=(divElement.offsetWidth*0.75)+'px';} else if ( divElement.offsetWidth > 500 ) { vizElement.style.minWidth='424px';vizElement.style.maxWidth='654px';vizElement.style.width='100%';vizElement.style.minHeight='629px';vizElement.style.maxHeight='929px';vizElement.style.height=(divElement.offsetWidth*0.75)+'px';} else { vizElement.style.minWidth='424px';vizElement.style.maxWidth='654px';vizElement.style.width='100%';vizElement.style.minHeight='629px';vizElement.style.maxHeight='929px';vizElement.style.height=(divElement.offsetWidth*0.75)+'px';}                     var scriptElement = document.createElement('script');                    scriptElement.src = 'https://public.tableau.com/javascripts/api/viz_v1.js';                   

          vizElement.parentNode.insertBefore(scriptElement, vizElement);                </script>



          map test.JPG

          • 2. Re: Problem with embed code
            Sophia Messini

            Hello Hemang,

            Thank you for your time but unfortunately didn't work to me. Is there any chance to have this problem because I have the free version of wordpress and I don't have plugin for iframes? I think I have read this somewhere in the forum, as a possibility. In my site the map is not interractive but it seams like a picture. Do you think that I have to upgrade my wordpress and what version it could be useful for me.

            Which version do you use?

            Here is the site with your embed code you wrote me ΕΚΛΟΓΕΣ 2007 | DATA JOURNALISM

            • 3. Re: Problem with embed code
              John Barr

              This feels like an issue I had when trying to embedded Tableau Public Dashboards on my site. I originally had a wordpress.com site but learned that I need a worpress.org site to take advantage of the Interactive visuals of Tableau Public. This has some background: Online Blog Service Compatibility | Tableau Software


              Wordpress.org do have fees so best to research before you convert. Blogger sites work fine.