Javascript File i/o

Thursday May 25th, 2000

Pete Collins from Alphanumerica and Mozilla developers have created a Javascript interface for doing file i/o in Mozilla, which will allow new Mozilla components like Alphanumerica's Crash Recovery system to function properly.

Patterned after the PHP filesystem functions, simple functions such as file read/write and directory create are supported. The code has not yet made it into the nightly build, but they expect it will get in soon.

Note from AN: There seems to be a misconception about Javascript File I/O being a security risk. It is important to clarify that this project is not opening any security holes in Mozilla. There is a difference between Javascript on the Internet and Javascript inside the application. Javascript is used inside Mozilla to create the functionality for the application. This is in contrast to any Javascript downloaded from the Internet that is used for functionality only inside a Web page. This project does not grant any access to Javascript found on the Internet. For more information about how Javascript is used inside Mozilla read more about XPCOM and XPConnect.

#27 Type 2 def is wrong

by mozineAdmin

Thursday May 25th, 2000 5:40 PM

You are replying to this message

Your type one def and type 2 defs sound the same.

However, in what you're calling Type 2, the "skin" can include XBL files, too, through the behavior property which is part of CSS3:


XBL files do not necessarily alter behavior through new javascript code, but they can alter structure, which in turn can incidentally alter behavior.

*But* XBL can also contain arbitrary code in its method tags. Therefore, there needs to be some way to distinguish XBL with the code from XBL without code, I would think, because XBL is allowed in skins (you can define a behavior in CSS:

menubar { behavior: url("URLREFHERE"); }

IE already supports this in its HTML components, apparently.

If you look in the current Mozilla skin, you'll see XBL is bound in for the back and forward buttons.