I’ve got a problem and I need some help. I’m building a semantic webby type thing where the web page you are viewing will be augmented with a menu showing other relevant info gathered from elsewhere using a clever algorithm which is already built. 

My first attempt was to build a page with an <iframe> in which to show the web content a la StumbleUpon. Trouble is, while you can set the URL of an iframe via JavaScript, you can’t read it when it’s on a different domain for security reasons. That means when a user navigates to a different page within the iframe, the semantic webby thing won’t know what information to display.

So here are some half-baked ideas. Any further cooking tips much appreciated.

  • Proxy all page views through a script on the same server as the semantic webby thing. This means all pages are on the same domain so JavaScript can see the iframe URL. But that means rewriting all the URLs in the page on-the-fly which is hard and it will almost certainly break any Ajaxy stuff since we’re effectively changing the domain of the page.
  • Create a browser plugin. Only really an option for Firefox.
  • Use AIR, which, as I understand it, has a version of WebKit built in. This also requires software installation and effectively means building a new browser interface in AIR.
  • Flash/Silverlight? Is it possible to embed a web page in a Flash or Silverlight file and access the page’s URL?

Anything else I haven’t thought of?

Please help!

Update: Thanks to @futureshape for suggesting Conduit which is a cross-browser drag & drop toolbar building platform. I looked into it and it would probably make IE development a bunch easier. However it turned out the project spec could be changed so that I can build the whole thing as a bookmarklet. Hooray for maleable specifications!