title: how to call a php class function directly using ajax?
body: <p>Is it possible to call a php class function DIRECTLY using ajax? </p>
  
  <p>Something like below... except ajax...</p>
  
  <pre><code>myclass::myfunction();
  </code></pre>
  
  <p>I've been using the jquery library to work with AJAX.</p>
  
  <pre><code>$.get('control.php', {func: funcName, arg1: arg1});
  </code></pre>
  
  <p>The above is similar to what I'm trying to achieve MINUS the control.php;</p>
  
  <p>I'm not sure if this is even possible, but I just thought it would be nice to skip the landing page (control.php) that recieves the funcName. I have a bunch of conditional statements that sort out what class function to run based on the funcName recieved. </p>
  
  <p>It seems kind of silly to do this, to have a separate page just to handle function calls. </p>
  
  <p>Is there a better way?</p>