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!
Array, since arrays are really meant to be numerically indexed.new Object()or just{}is the right choice.