i am working with JS and AS3 to get default mic. below is my html code
js on head
$(document).ready(function(){
$("#setupMic").click(function() {
try{
document.getElementById('test').setupMic();
} catch(err) {
console.log(err.message);
}
});
});
js after div flashContent
var callback = function(e){ if(e.success) console.log("Loading Success"); else console.log("Loading Failed");};
var flashvars = {};
var params = {allowscriptaccess:"always"};
var attributes = {};
attributes.id = "test";
swfobject.embedSWF("test.swf", "flashContent", "220", "140", "10", false, flashvars, params, attributes, callback);
my AS3 code is
import flash.system.Security;
import flash.external.ExternalInterface;
var mic:Microphone;
Security.allowDomain('*');
ExternalInterface.addCallback("setupMic", setupMic);
function setupMic():void {
mic = Microphone.getMicrophone();
mic.setLoopBack(true);
}
the html is working perfectly in firefox. but not with my chrome or safari on friends mac. what am i missing. please help