Is there a JavaScript equivalent of Java\'s class.getName()?
class.getName()
Say you have var obj;
var obj;
If you just want the name of obj's type, like "Object", "Array", or "String", you can use this:
Object.prototype.toString.call(obj).split(' ')[1].replace(']', '');