title: JavaScript JSON Table Matching
body: <p>I've been going through hell trying to figure this out, i'm sure it's not that big of a deal, perhaps i'm just tired from coding all night, but I could really use some help... </p>
  
  <p>"users" is a database-like object containing user account information ( server-side, of course ), "get" is a function that returns an array of matching objects from the users array.</p>
  
  <pre><code>var users = [
      {
          name:"xymon",   
              age:19,
          pass:"mypass",  
          time:1364101200684
      },
      {
          name:"test",    
              age:19,
          pass:"x",   
          time:1364101200993
      },
      {
              name:"test",
              age:19,
              pass:"bleh",
              time:1364101200992
      }
  
  ];
  
  function get(a){
  
  }
  </code></pre>
  
  <p>What I'm wanting "get" to do is return properties that match the specified object (a) in an array, like so...</p>
  
  <pre><code>var matching_users = get({name:"test",age:19});
  </code></pre>
  
  <p>This would return the two objects in the "users" array because their properties match the specified properties in "get" so that "matching_users" would return as...</p>
  
  <pre><code>[
      {
          name:"test",    
              age:19,
          pass:"x",time:1364101200993
      },
      {
              name:"test",
              age:19,
              pass:"bleh",
              time:1364101200992
      }
  
  ]
  </code></pre>