easily get information from script
getDetailFromScript = function(script, name) {
var data = script.replace(/\s*=\s*/g, "=");
var escapeSequence = ["\\", ".", "(", ")", "[", "]", "{", "}", "^", "$", "|", "*", "+", "?"];
for(var key in escapeSequence) {
name = name.replace(escapeSequence[key], "\\" + escapeSequence[key]);
}
var results = new RegExp(name + "=([^;]*)").exec(data);
if(results === null) {
return null;
} else {
return results[1];
}
}; //end getDetailFromScript