I know this is not allowed by google, and i can get my adsense acount banned but i will take the risks :D
The scenario is: Google gives you a script to put in your page.
<script type="text/javascript">
google_ad_client = "ca-pub-xxxxxxxxxxxx";
google_ad_slot = "xxxxxx";
google_ad_width = 300;
google_ad_height = 250;
</script>
<script type="text/javascript" src="//pagead2.googlesyndication.com/pagead/show_ads.js"></script>
When the page loads, this script generates an iframe, we will call it iframe A
Iframe A contains contains a html page with 2 iframes in it, we will call it iframe B and iframe C. So far we have an iframe that contains 2 iframes inside. The second iframe, iframe C, contains a link.
All I want to do is "To open the link in new tab" :D
I can do this by adding with javascript attribute target="_blank".. BUT i CANT select the link() with javascript because the iframe is from another site. For security reasons browsers dont let you to access the content of an iframe if is not from your site.
I am loking for some sort of a hack... I was thinking if playing with events will help me ?
Like catching the event of link click, than stop the event and than fire new event to open link in new tab.
Or catch the leftclick event, stop event, fire right click event than, from the cotext menu select "open link in new tab" (all of this happens when user leftclick the link)
Any suggestions are welcome, I need to look this problem from a different perspective...