Accessing an IMG tag within an IFRAME

T

threepins

Hi,

I was wondering if it is possible to access an <img> tag that is buried
within some external content in my site that is contained within an
iFrame on a page within my site... confusing i know! For example:

<html>
<head>
....
</head>
<body>
....
<div>
<iframe src="http://contentfromanothersiteihave">
<img src="img i want to get">
</iframe>
</div>
</body>
</html>

Obviously the ... means there is other stuff in there. Basically i want
to show the img from the other content but hide the rest of the content
on that page that is being loaded in the iframe. However, i'm not too
great with javascript and using document.images only references one
image (the main site's logo image).

Any help would be greatly appreciated.

Cheers
Bj
 
D

David Dorward

I was wondering if it is possible to access an <img> tag that is buried
within some external content in my site that is contained within an
iFrame on a page within my site.

I doubt it. Security considerations put rather strict limits on what
JavaScript running from a webpage on one host to a page on another.

If you can, then the answer is in the FAQ.
http://jibbering.com/faq/#FAQ4_8
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top