I have a SharePoint webpart page, with a parameter in the page Querystring (in the URL), and I also have a Page Viewer webpart (which effectively IFRAME's the specified webpage), which shows a Java applet.
Is there any way I can get the parameter in the SharePoint Querystring to be recieved by the Java Applet ?
The reason for doing a Java applet in a webpart is to allow a file to be dragged and dropped onto the Java applet, and the parameter shows where the file would be saved in the SharePoint Document Centre.
I'd appreciate any and all suggestions.
Cheers
Nick
Notes:
- The Querystring in the sharepoint page cannot be read by the Java Applet directly, due to the 'walls' setup around the Page Viewer webpart.
- I've tried creating a cookie when the SharePoint page is loaded, then reading the cookie when the Java applet is loaded (upon recieving the file, so it's not a timing thing), but it can't access the cookie (different domains ?)
Best Answer
Sounds like your two webpages run from different domains. In that case, you need to use one of the Cross-Domain Communication tricks to break the walls.
Read this article,
http://msdn.microsoft.com/en-us/library/bb735305.aspx
This is my favorite approach. To summarize it,
The xd_helper Javascript can be very simple. Look at the one used by Google Friend Connect,
Facebook uses a more verbose version,
http://static.ak.facebook.com/js/api_lib/v0.4/XdCommReceiver.js?2