Ciao qualcuno mi aiuta?
Ho un div in cui facebook carica un iframe e inserisce il pulsante condividi (attraverso una chiamata ajax alla API).
Sto cercando di far si che alla pressione di un tasto (per ora 'enter') si apra il popup di facebook
Il problema è che mi restituisce questo errorecodice:if(e.keyCode==13){ //TODO: millemila condizioni console.log('clicked'); var a=$('#fbs>div>span>iframe').contents();//<-ERRORE var b=a.find('pluginShareButtonLink'); b.click(); }
Uncaught SecurityError: Blocked a frame with origin "*MIOURL*" from accessing a frame with origin "https://www.facebook.com". The frame requesting access has a protocol of "http", the frame being accessed has a protocol of "https". Protocols must match
Che devo fare? (la mia pagina è in http)
Tutto questo perché i maledetti social network non mettono a disposizione protocolli standard e unificati...
EDITcon twitter altro errore)
Uncaught SecurityError: Blocked a frame with origin "****" from accessing a frame with origin "http://platform.twitter.com". The frame being accessed set "document.domain" to "twitter.com", but the frame requesting access did not. Both must set "document.domain" to the same value to allow access.