title: Pass array of data to jQuery function
body: <p>Here's the story... I have a jQuery function that does something, this function is referenced very regularly. One of the input parameters is an array, this array data is hard coded and thus I want to pass the data like this: (this is how I would do it using PHP)</p>
  
  <pre><code>myFunction(Array("url"=&gt;"abc.com","example"=&gt;"hello_world"));
  </code></pre>
  
  <p>Instead of </p>
  
  <pre><code>$arr=Array("url"=&gt;"abc.com","example"=&gt;"hello_world");
  myFunction($arr);
  </code></pre>
  
  <p>So how do I achieve this with my jQuery function, I want this to be a one liner if possible.</p>
  
  <p><strong>Edit</strong></p>
  
  <p>Maybe my example was a bit misleading, take a look at the array indexes again. The array I am sending is an associative array.</p>
  
  <p>In short I do not want any variables before my function, I want the array to be hardcoded directly in the function parameter as suggested in the first example I gave.</p>
  
  <p>:-)</p>