Solved

permission denied to get property Location.host

Posted on 2006-10-19
2
674 Views
Last Modified: 2010-07-27
I have a page that has a third party blogging page included as a frame. That third party page includes some js fro mmy site (different domains). I get a "permission denied to get property Location.host" when in the frameset from the blogging third party page. Why and is there anyway to get around this? I can't change the js that is looking for the location.host.
0
Comment
Question by:894359
2 Comments
 

Author Comment

by:894359
ID: 17769401
This is what I found so far;

 Security restrictions prevent a script in one frame from accessing location object information in another frame if the document in the second frame does not come from the same domain (and the same server, unless the document.domain properties of the two documents are set to match) as the document with the nosy script. This prevents a rogue script from monitoring navigation in another frame to external web sites. In Navigator 4 and later, you can overcome the security restriction with the help of signed scripts, but the user still has to give explicit permission for a script to access location object information outside the script's domain.
0
 
LVL 12

Accepted Solution

by:
netsmithcentral earned 500 total points
ID: 17770354
Unfortuanately, what you've found is mostly true.  Without using server side scripting (which would let you pull the entire script for transplanting into your page), or putting a copy of the scripts on your blog page's domain, you can't access them.  It's a security feature, and a pretty good one at that.
0

Featured Post

Are your AD admin tools letting you down?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article, we'll look how to sort an Array in JavaScript, including the more advanced techniques of sorting a collection of records either ascending or descending on two or more fields. Basic Sorting of Arrays First, let's look at the …
I've been trying to accomplish this for a while and it just struck me yesterday how to accomplish this task. I have done searches all over the internet looking for ways to email pages from my applications and finally I have done it!!! Every single s…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question