Had similar problem using PHP4 on Apache WinXP, trying to connect to Win2k ftp server.
The only way it will work is if I type in an IP address in the ftp_connect function.
I wanted to set the IP address or hostname to a string ie:
$string="xxx.xxx.xxx.xxx";
$connid=ftp_connect($string);
ftplogin($connid, $username, $password);
but it just gave me the 'Unable to find ftpbuf 0' error.
If I do the following, however,
$connid=ftp_connect("xxx.xxx.xxx.xxx");
ftplogin($connid, $username, $password);
it works.
I don't understand why... and it's just lucky that there's only one ftp site I want to use, can't put 'selection' criteria into the script.
Anyway, hope this helps a bit.
Jase