From: Enver ALTIN (enver.altin@frontsite.com.tr)
Date: Sat 27 Dec 2003 - 12:58:36 EST
On Sun, 2003-12-28 at 16:14, Halil Demirezen wrote:
> Selam arkadaslar,
Merhaba,
> php de ftp fonksiyonlarini kullanarak dosya acma
> yapiyorum. Diyelim dosya yok bu sefer "none" diye
> 4 karakterlik bir string donduruyor. benim istedigim
> null dondurmesi. Bunu apache ve php.ini kullanarak
> nasil duzeltebiliriz? Yolu var midir?
PHP'de boyle bir sorun yok. Kullandiginiz surumu kontrol edebilir
misiniz? Genel olarak PHP'de hicbir fonksiyon hata durumunda
bahsettiginiz gibi 'none' dondurmez; genellikle FALSE dondurur.
Description
resource ftp_connect ( string host [, int port [, int timeout]])
Returns a FTP stream on success or FALSE on error.
Dogru kullanim bicimi:
<?php
define ("FTP_SERVER", "ftp.myserver.com");
define ("FTP_USER", "user");
define ("FTP_PASSWORD", "pass");
if ($ftpconn=ftp_connect(FTP_SERVER)) {
if ($ftplogin=ftp_login($ftpconn, FTP_USER, FTP_PASSWORD)) {
// Buraya diger FTP islemleri
}
ftp_close($ftpconn);
} else die ("Baglanilamiyor.");
?>
gibi birseyler olmali.
-HTH
-- __________ | | | | Enver ALTIN (a.k.a. skyblue) | | Software developer, IT consultant | FRONT | |==========| FrontSITE Bilgi Teknolojisi A.Ş. |_____SITE_| http://www.frontsite.com.tr/ -- Attached file included as plaintext by Ecartis -- -- File: signature.asc -- Desc: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.3 (GNU/Linux) iD8DBQA/7chLZCB2FZvqK0sRAvbqAJ43GajL41vRVAUEEshxknpzV7t2agCfZBsH 1wt6B4zelNLJ4nHwPfrPBXI= =NNmf -----END PGP SIGNATURE-----