Dynamic static method call in PHP?

Solution 1:

Use the call_user_func function:

http://php.net/manual/en/function.call-user-func.php

Example:

call_user_func('myClassName_' . $language . '::myFunctionName');

Solution 2:

I think you could do:

$classname = 'myClassName_' . $language;
$result = $classname::myFunctionName();

This is called Variable Functions