Connecting Tech Pros Worldwide Help | Site Map

IFrame problem.

 
LinkBack Thread Tools Search this Thread
  #1  
Old November 17th, 2006, 10:55 AM
vamsee.2005@gmail.com
Guest
 
Posts: n/a
Default IFrame problem.

Hi guys,

I wrote a greasemonkey to directly post bookmarks to del.icio.us and my
script shows an icon on the page. upon clicking it, it will create an
iframe and allow us to post the bookmark. The problem is my icon is
showing up even in iframes, I just want to show the parent window only.

How can I detect a page whether its served in iframe or parent window ?


  #2  
Old November 17th, 2006, 12:35 PM
ASM
Guest
 
Posts: n/a
Default Re: IFrame problem.

vamsee.2005@gmail.com a écrit :
Quote:
Hi guys,
>
I wrote a greasemonkey to directly post bookmarks to del.icio.us and my
script shows an icon on the page. upon clicking it, it will create an
iframe and allow us to post the bookmark. The problem is my icon is
showing up even in iframes, I just want to show the parent window only.
Which parent window ?
This where is the icon-image-button ?
Quote:
How can I detect a page whether its served in iframe or parent window ?
Isn't it to you to decide where you send your pages ?

location = 'page.htm';
self.location = 'page.htm';
parent.location = 'page.htm';
top.location = 'page.htm';
parent.myIframe.location = 'page.htm';

<img name="iconnette" src="icon.jpg" onclick=" ... >
<iframe name="myIframe" onload="deletIcon()" ... ></iframe>

function deletIcon() {
var Ic = parent.myIframe.document.iconnette;
if(Ic) Ic.style.display = 'none';
}

--
Stephane Moriaux et son (moins) vieux Mac déjà dépassé
Stephane Moriaux and his (less) old Mac already out of date
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,989 network members.