This is probably a stupid question. Firefox is rather rigid, as Internet Explorer is to be known to activate virusses without a problem. But for my English classes I need eSpeak without the command screen. The program is run local, but I use HTML with javascript.
This is my code:
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
var localFile = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);
var process = Components.classes["@mozilla.org/process/util;1"].createInstance(Components.interfaces.nsIProcess);
var args = new Array('-vmb-en1',"Say something");
localFile.initWithPath('C:\\WINDOWS\\espeak.exe');
process.init(localFile);
process.run(false, args, args.length);
I want to hide the prompt in Firefox. Internet Explorer does what I want with:
try{var speak = new ActiveXObject('WScript.Shell');} catch(err){}
speak.Run('espeak -vmb-en1 "Say something"',0);
Any other suggestion to change the code is welcome.