Hi,
This is my first message to this forum.I am facing one problem in frames.when i am trying to access child frame from parent frame i am getting "Access Denied Error".i know the reason bcz i am trying to access the frame in different domain.is there any way to tackle this problem
my code:
parent frame:
<html>
<script>
function displayURL(){
alert("child frame URL="+self.chil dframe1.locatio n.href);
// above line i am getting the 'Access Denied Error'
}
</script>
<frameset id="mainframe" rows="100%,*" border="0">
<frame id="childframe1 " name="childfram e1" src="child1.php " onload="display URL()">
</html>
child frame: child1.php:
<html>
<script type="text/javascript">
function displaygoogle() {
parent.childfra me1.location.hr ef="http://www.google.com" ;
}
</script>
<body>
<a href="javascrip t:displaygoogle ();">Display Google</a>
</body>
</html>
When the page is getting loaded for first time.the alert box is displaying as "child frame URL=http://www.ABC.com/child1.php". suppose when i click the 'Display google' link in child frame,the google web site is displaying in my child frame but the alert box is not displaying "it's telling Access Denied Error".
A.suresh
6 3464
Hi,
This is my first message to this forum.I am facing one problem in frames.when i am trying to access child frame from parent frame i am getting "Access Denied Error".i know the reason bcz i am trying to access the frame in different domain.is there any way to tackle this problem
my code:
parent frame:
<html>
<script>
function displayURL(){
self.childframe 1.location.href ="http://www.google.com" ;
alert("child frame URL="+self.chil dframe1.locatio n.href);
// this line i am getting the 'Access Denied Error'
}
</script>
<frameset id="mainframe" rows="100%,*" border="0">
<frame id="childframe1 " name="childfram e1" src="child1.php ">
</html>
child frame:(child1.p hp):
<html>
<body>
<a href="javascrip t:parent.displa yURL();">Displa y Google</a>
</body>
</html>
When the page is getting loaded for first time.the alert box is displaying with "http://www.ABC.com/child1.php". suppose when i click the 'Display google ' link in child frame,the google web site is displaying in my child frame but the alert box is not displaying "it's telling Access Denied Error".
b1randon 171
Recognized Expert New Member
Hi,
This is my first message to this forum.I am facing one problem in frames.when i am trying to access child frame from parent frame i am getting "Access Denied Error".i know the reason bcz i am trying to access the frame in different domain.is there any way to tackle this problem
my code:
parent frame:
<html>
<script>
function displayURL(){
self.childframe 1.location.href ="http://www.google.com" ;
alert("child frame URL="+self.chil dframe1.locatio n.href);
// this line i am getting the 'Access Denied Error'
}
</script>
<frameset id="mainframe" rows="100%,*" border="0">
<frame id="childframe1 " name="childfram e1" src="child1.php ">
</html>
child frame:(child1.p hp):
<html>
<body>
<a href="javascrip t:parent.displa yURL();">Displa y Google</a>
</body>
</html>
When the page is getting loaded for first time.the alert box is displaying with "http://www.ABC.com/child1.php". suppose when i click the 'Display google ' link in child frame,the google web site is displaying in my child frame but the alert box is not displaying "it's telling Access Denied Error".
If you want to cross domains you will have to do it from your server as nearly every browser will not allow this because it is such a security risk.
Hello sir,
Can you ellaborate your idea briefly.
A.suresh
acoder 16,027
Recognized Expert Moderator MVP
Can any help me this isue.
i am setting self.childframe 1.location.href ="http://www.google.com" ;
from parent frame.whether the above fn will replace the child frame src value to 'google.com' .
bcz After displaying the google.com website in my child frame.i checked this option alert("frame HTML="+document .getElementsByT agName('framese t')[0].innerHTML);
Its displaying the original frame src that is "frame HTML=<frame id='childframe1 ' src='child.php' ></frameset>".
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Brian |
last post by:
Hi all,
So, I posted a question about a DOM inspector for IE (mozilla comes with
one, which is pretty nice).
Since I got no reply, I wrote my own, which works pretty well. It is laid
out like the mozilla one, but isnt quite as nice, because I did not want to
spend too much time with it.
Anyways, I implemented it with frames, where one frame contains the source
|
by: Sergio del Amo |
last post by:
Hi,
I implemented a Web-Site based in remote scripting with hidden frames. I
am using Javascript to provide dynamic functionality. In the machine's
local server works perfectly but when i uploaded to my hosting site i
obtain:
Error "Access Denied" Code:0
The function where i get the error is the next. Exactly in the line 31
27: function serverLoad(pX,rX)
|
by: ASP.Confused |
last post by:
The old message looked a little stale, so I am re-posting it here. Anybody
have any ideas of what I could do?!? The previous responses to this
question are below. If you want to look at the original question, the
subject line is:
ADODB.NET and "Access Denied"
I have an ASP.NET page writtein in VB that uses ADODB. I just had to
|
by: HelenWu |
last post by:
I have two frames in index.html:
<frameset cols="165,*">
<frame name="NCTnav" src="NCTnavHome.htm" scrolling="auto">
<frame name="NCTmain" src="http://www.yahoo.com">
</frameset>
from frame "NCTnav", I have a link, when I click this link, I need to load http://www.google.com (for example) into frame "NCTmain". The code in NCTnavHome.htm like:
<script language="JavaScript" type="text/JavaScript">
function...
|
by: srivatsans101 |
last post by:
Hi,
I'm trying to access the IFrame contents on a HTML page as
frames.document
But in IE, I'm getting Access Denied Error Message.
I tried to add the IFrame's Src WebSite (a local/intranet hosted dynamic HTML page) to Trusted Sites list in IE Options.
| |
by: Angel |
last post by:
I am using coolmenus 4, frames version by DHTMLcentral.com. When I
click on any of the submenus, I get an "Permission Denied" error.
There after the menus stop working. The cursor on the menu changes to
input text kind rather than the normal hand pointer that appears when
you mouse over a link.
If any of you guys have used Coolmenus please help out.
Alteranately, if there are any versions of dropdown menus for frames
please let me...
|
by: SSG001 |
last post by:
i have a form and in that i iframe
in the main form
<form name='form1>
<iframe name="frame1" id="iframe1" src="iframe1.php" scrolling="yes" width="300%" frameborder="0" height="300"></iframe>
<input type="button" name="save" onclick="save();">
</form>
function save(){
window.frames.document.forms.add.click();
document.form1.submit();
|
by: doby48 |
last post by:
I have a JavaScrip that runs fine under all browsers except IE. I am opening up a document within an iframe and I get the error of Permission Denied in IE. I know that IE has security that will throw that error if the pages are on a different domain but in this case they are all on the same domain. The pages are in a subdirectory but I am referencing them accordingly and not calling a different domain. My code is as follows:
<SCRIPT...
|
by: Chico Che |
last post by:
I have a ie window that launches a pop up window with no menus/toolbars
nothing just the page. When I run an bookmarklet on main window it works
fine but when I try running this on the popup I get an access denied error.
All the javascript is doing is getting innertxt from a textbox. It works
fine when main window is done but when popup is used it does not work. If
anybody can help would greatly appreciate it.
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |