View Single Post
Old January 19th 2007, 01:39 PM   #1 (permalink)
JTiger2k
Registered User
 
Join Date: Jan 2007
Posts: 1
Is this possible??

I have a page hosted on one server that we are coding in.

A have an iframe loading content from another of our sites that runs a site package whose pages contain javascript.

When you click a javascript link in the iframe it executes a function from within the iframe. Herein lies my problem. I wan't it to execute a different javascript function from the iframe, but I cannot change the code on that server as we get updates all the time and they would not support the application anymore if we do. So, I'm trying to intercept those function calls and execute another function.

I've tried to assign a new function there but it's not working. See code snipet below.

Code:
function showalert() {
    alert('Link Disabled');
    }

var newFunction = showalert;

parent.frames["iframe_sample1"].openWindow = newFunction;
Any help with this is much appreciated, as my javascript is a bit rusty...

- JT
JTiger2k is offline   Reply With Quote
Forum Advertisement ** This Advertisement Does Not Show To Registered Users **