Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

Getting the SP URL from within a Page Viewer WP

  Asked By: Jessika    Date: Feb 17    Category: Sharepoint    Views: 1463

Does anyone know how, or can anyone think of a way, to get the parent
site's url from within a page viewer web part? The javascript function
parent.location.href (in IE7) returns an access denied error.
Everything else that I've tried just returns the url of the page
connected to the page viewer, rather than of SP itself.



2 Answers Found

Answer #1    Answered By: Chris Daniel     Answered On: Feb 17

Have you tried top.location.href instead?

Answer #2    Answered By: Lynn Mann     Answered On: Feb 17

Making progress
That eliminates the error, but it still doesn't actually retrieve the
value of the "top" url. It returns  the value of the iframe url. Any
other ideas?

Didn't find what you were looking for? Find more on Getting the SP URL from within a Page Viewer WP Or get search suggestion and latest updates.