Friday, August 10, 2007

JavaScript Hash

var animalColors = {'ape':'black', 'pig':'pink', 'frog':'green'}
 
alert(animalColors['ape'])
 
alert(animalColors.ape)
 
 

No comments: