Troubleshooting "call_user_func_array() expects parameter 2 to be array, string given" error
<pre><code>if( array_key_exists( $fn, $this-&gt;_request ) ){
if( $array ){
    $result = call_user_func( $func, $args );
}else{
    $result = call_user_func_array( $func, $args );
}
if( !empty( $GLOBALS['xhrErrorHandlerText'] ) ){
    $error = 'PHP Error Message: ' . addslashes( $GLOBALS['xhrErrorHandlerText'] );
}
}else{
if( $fn ){
    $error = 'Cannot call function '. addslashes( $fn ) .'. Function not registered!';
}else{
    $error = 'No function call specified!';
}
}
</code></pre>

<p>I'm getting this error:</p>

<blockquote>
  <p>PHP Error Message: WARNINGcall_user_func_array() expects parameter 2
  to be array, string givenError in line 649 of file</p>
</blockquote>
