title: Return value of function to parameters object in jquery click method
body: <p>I have the following code:</p>
  
  <pre><code>$('a.display').click({
      p1: $(this).attr('href'),
      p2: '#' + $(this).parents().filter(function () {
          return $(this).attr('class') == 'display';
      }).id
  }, display);
  </code></pre>
  
  <p>I'm trying to pass the actual values of the functions being performed in object element p1 and p2 to my display function which takes two parameters. Instead it's returning the whole function.  Is there something different I can do to achieve what I'm trying to do?  </p>