title: php: Declare arguments type of a Function
body: <p>I'm trying to make a function with declared argument types, to quickly check if they are in the right format, but when it returns a string I this error: </p>
  
  <p><code>Catchable fatal error: Argument 2 passed to myfunction() must be an instance of string, string given, called in path_to_file on line 69 and defined in path_to_file on line 49</code></p>
  
  <p>Example</p>
  
  <pre><code>function myfunction( array $ARRAY, string $STRING, int $INTEGER ) { 
      return "Args format correct"; 
  }
  myfunction(array("1",'2','3','4'), "test" , 1234);
  </code></pre>
  
  <p>Where is the mistake?</p>