protected function findGlobalBinary($binary)
    {
        $command = sprintf('where %s', $binary);
        $result = shell_exec($command);

        return trim($result);
    }
protected function findGlobalBinary($binary)
    {
        $command = sprintf('where %s', $binary);
        $result = shell_exec($command);

        return trim($result);
    }
protected function findGlobalBinary ( $ binary ) { $ command = sprintf ( 'where %s' , $ binary ) ; $ result = shell_exec ( $ command ) ; return trim ( $ result ) ; }
Use 'where' on Windows to find a binary, rather than 'which'
@param string $binary
@return null|string
Use where on Windows to find a binary rather than which