hej..
Jeg forsøger ik på noget "like" jacking eller noget, ville bare vide om det var muligt at få javascript/jquery til at trykke på knappen inde i iframen? eller om det på anden måde er muligt at lave en custom google+ knap
Google+ knap:
- <div
- id="___plusone_0"
- style="height: 24px; width: 106px; display: inline-block; text-indent: 0pt; margin: 0pt; padding: 0pt; background: none repeat scroll 0% 0% transparent; border-style: none; float: none;">
- <iframe
- width="100%"
- scrolling="no"
- frameborder="0"
- vspace="0"
- tabindex="-1"
- style="position: static; left: 0pt; top: 0pt; width: 300px; margin: 0px; height: 24px; visibility: visible; display: none;"
- src="https://plusone.google.com/u/0/_/+1/fastbutton?url=http%3A%2F%2F192.168.100.203%2Fuser%2Fkenneth&size=standard&count=true&db=1&hl=en-US&jsh=r%3Bgc%2F22821001-a70f00f0#id=I1_1312813406985&parent=http%3A%2F%2F192.168.100.203&rpctoken=117417457&_methods=onPlusOne%2C_ready%2C_close%2C_open%2C_resizeMe"
- name="I1_1312813406985"
- marginwidth="0"
- marginheight="0"
- id="I1_1312813406985"
- hspace="0"
- allowtransparency="true">
- <html>
- <head>
- <link href="/_/apps-static/_/ss/plusone/ver=4x6d5pec1j7r/am=!sg87bdX_5LnwfGiw/bf=wg/r=O" rel="stylesheet">
- </head>
- <body class="a-Fh-Ib-F7">
- <div id="root">
- <script type="text/javascript">
- window.__SSR = {'si': 1,'e': '----@gmail.com','dn': 'Kenneth Jakobsen','is': 0};
- </script>
- <div class="a-tc-e-Zi" style="position: absolute;" id="plusone">
- <div class="a-tc-wV">
- <a tabindex="0" role="button" title="Click here to publicly +1 this as Kenneth Jakobsen (----@gmail.com)." class="a-tc-kg-e a-tc-kg-Nf-e a-tc-e-Zi" id="button" href="javascript:void(0);" aria-pressed="false"></a>
- </div>
- <div class="kG">
- <div class="ZM"></div>
- <div class="XM" id="aggregateBubble" title="0 people +1'd this">
- <div class="YM" id="aggregateCount">0</div>
- </div>
- <div class="aN"></div>
- </div>
- </div>
- </div>
- <script type="text/javascript">
- window.__PVT = 'APfa0brNg0pY8wOwH2yc844HVLhzazYCry8C1N0EMTyJD35y1CYRFiUjoh0s34XEC3eowucKYxmI';
- window.__GOOGLEAPIS = {googleapis: {versions: {pos: 'v1'}}};</script>
- <script type="text/javascript">window['__P1_BASEURL'] = 'https://plusone.google.com/u/0/'; window['__P1_LOCALE'] = 'en_US';
- var _DumpException = function(e) {
- e['errsource'] = e['errsource'] || 'api_widget';
- throw e;
- }
- </script>
- <script src="https://ssl.gstatic.com/webclient/js/gc/22821001-a70f00f0/googleapis.client__plusone.js"></script>
- <script type="text/javascript">iframes.ready({'height': 24.0 });</script>
- <script src="/_/apps-static/_/js/plusone/p1b,p1ctrl/rt=j/ver=jcdTGnQlqFs.en_US./am=!sg87bdX_5LnwfGiw/d=1/"></script>
- </body>
- </html>
- </iframe>
- </div>
Prøvet:
- <g:plusone></g:plusone>
- <a class="cus_google_plus" href="#">Google+</a>
- $("iframe").hide();
- $("a.cus_google_plus").click(function(){$("iframe").contents().find("a#button").click(); return false;});
men pga cross domain får jeg fejl.
"Permission denied to access property 'ownerDocument'"