after progging php since 3 years, im hanging at javascript. Is it possible to get value of an assoziative array with a variable? Example:
var a = new Array();
a["ANDI"] = "USER";
var test = "ANDI";
alert(a[test]);
Any suggestions, how I could workaround that? Maybe with objects?
Thx for help!
Arrays are indexed by numbers. Objects have properties that can be accessed by name.