I can't modify the following html:
<iframe src="http://google.com/foo" width="600" height="338" frameborder="0" webkitAllowFullScreen allowFullScreen></iframe>
<div style="padding:5px 0; text-align:center; width:600px;"><p>
<a href="http://www.foobar.com/lol/wut">Some Link</a></p></div>
I need to target this element:
<a href="http://www.foobar.com/lol/wut">Some Link</a>
The requirements are:
- the first link after the iframe whose src starts with the domain http://google.com
Since I can't edit the html I can't simply add an id and use document.getElementById. So how can I target the link using just plain js?