> Basically chrome and opera prevent XmlHttpRequest from working when
> the file is local (to prevent cross site scripting issues). But
> wouldn't this be able to be worked around using a java plugin?

While I reckon that might be possible, it's a bit of a can of worms.

Nevertheless, that shouldn't stop you from experimenting:
     http://svn.tiddlywiki.org/Trunk/core/java/
     http://svn.tiddlywiki.org/Trunk/core/js/Http.js

Some quick googling reveals the following:
     http://www.exampledepot.com/egs/java.net/ReadFromURL.html

 From that I created this addition to TiddlySaver.java:
---------------
public class TiddlyProxy extends java.applet.Applet {
  public String loadPage(final String uri, final String charset) {
   return (String)AccessController.doPrivileged(new PrivilegedAction() {
    public Object run() {
     try {
      URL url = new URL(uri);
      StringBuffer data = new StringBuffer();
      BufferedReader in = new BufferedReader(new
       InputStreamReader(url.openStream()));
      String line;
      while((line = in.readLine()) != null) {
       data.append(line).append("\n");
      }
      in.close();
      return data.toString();
     } catch(MalformedURLException e) {
      e.printStackTrace(); // XXX: ?
      return null;
     } catch(IOException e) {
      e.printStackTrace(); // XXX: ?
      return null;
     }
    }
   });
  }
}
---------------
(entirely untested, plus I'm not a Java guy)

Of course some additional client-side code would be required to make use 
of the applet.


-- F.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TiddlyWikiDev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/tiddlywikidev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to