javascript - Facebook pixel seems to works with img but not with js -


i'm new facebook pixel, might miss something... i've dynamically implemented code in header (wordpress website), , here what's generated on homepage example:

<!-- facebook pixel code --> <script>     !function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callmethod? n.callmethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;     n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createelement(e);t.async=!0;     t.src=v;s=b.getelementsbytagname(e)[0];s.parentnode.insertbefore(t,s)}(window,     document,'script','//connect.facebook.net/en_us/fbevents.js');     fbq('init', '--correct_fb_pixel_id--');     fbq('track', 'viewcontent', {         content_type: 'page',         content_ids: ['2'],         content_name: 'home'     }); </script> <noscript>     <img src="https://www.facebook.com/tr?id=--correct_fb_pixel_id--&ev=viewcontent&cd[content_name]=home&cd[content_type]=page&cd[content_ids]=2&noscript=1" height="1" width="1" style="display:none"/> </noscript> <!-- end facebook pixel code --> 

i've checked facebook pixel id, , it's correct. if use chrome extension "facebook pixel helper", see 2 calls, 1 correct (the 1 made image), , other not (the js call).

facebook pixel error

any idea why js call fails? lot help!

matt

--- edit ---

here information "successful" pixel: successful pixel


Comments

Popular posts from this blog

inversion of control - Autofac named registration constructor injection -

verilog - Systemverilog dynamic casting issues -

ios - Change Storyboard View using Seague -