views:

26

answers:

2

what is the meaning of this code:

aoData.push({"name":"more_data","value":"my_value"});

where is more_data and my_value get from?

+1  A: 

*more_data* and *my_value* are strings... that means that value never change! They aren't variables!

aoData is an array, and push is adding in the array that values...

push function is like $arrayvar[] = "test"; on the PHP

It adds the value to the end of the array...

CuSS
A: 

aoData is an array defined somewhere and with push more elements are pushed into the array.

See:

Push Method

Sarfraz