From: Samuele P. <ped...@bl...> - 2001-12-01 10:23:40
|
For the minimal common capability related to what you ask for applets see: http://java.sun.com/docs/books/tutorial/applet/appletsonly/index.html http://java.sun.com/docs/books/tutorial/applet/appletsonly/browser.html regards, Samuele Pedroni. ----- Original Message ----- From: Gary Herron <res...@ve...> To: dman <ds...@ri...>; <jyt...@li...> Sent: Friday, November 30, 2001 11:49 PM Subject: Re: [Jython-users] Questions about Jython and browser applets > Another applet related question: > > Can an applet communicate with or control the browser in which it is > running? Can it cause its own window or another (perhaps newly > created) window request and display a URL of its choosing? Can it > close down browser's window? Or can it communicate with javascript > where all these things are easily accomplished? > > Most importantly if any communication from an applet to the browser is > possible, what is a good resource to learn more about this? > > Thanks, > Gary. > > > > > On Thursday 29 November 2001 08:47 pm, dman wrote: > > On Thu, Nov 29, 2001 at 03:43:08PM -0800, Gary Herron wrote: > > | I'm very familiar with CPython, but I know almost nothing about > > | Jython, and even less about writing browser applets, so this brings me > > | to several questions. > > | > > | My application, which is mostly viewable on a browser as static web > > | pages and flash movies with a little javascript thrown in, now has a > > | need to execute a small amount of code on the users machine. I'd like > > | to write that code in Jython and have the user's browser download and > > | execute it as an applet. > > | > > | The hitch is that the applet must access things which, I think, are > > | not allowed for applets, such as > > > > what a hitch! > > > > | creation of files somewhere on the hard disk > > | calls to os.system -- does Jython even HAVE os.system or equiv? > > > > Not built-in, however this can be made from the java classes quite > > easily. I would paste in what I had, but I can't access that > > project's source right now (and I don't want to give you buggy stuff > > off the top of my head). > > > > | Is it true that suc access is not normally available from an applet? > > > > yes. > > > > | Is there a way to create applets that have this kind of access to the > > | user's system? > > > > yes. > > > > | Can the user decide, if he trusts me sufficiently, to grant an applet > > | such access? > > > > yes. To do so requires signing the applet, I think, so that the > > browser prompts the user to either grant or deny the permission. For > > galeon or mozilla on linux the user can create a ~/.java.policy file > > to give rights to an applet, regardless of whether or not it is > > signed. I used this to demo an applet I made that needed EJB > > and naming services. > > > > HTH, > > -D > > _______________________________________________ > Jython-users mailing list > Jyt...@li... > https://lists.sourceforge.net/lists/listinfo/jython-users > |