PHP ftp_systype() Funzione
Esempio
Ottieni il tipo di sistema del server FTP:
<?php
// connect and login to FTP server
$ftp_server = "ftp.example.com";
$ftp_conn = ftp_connect($ftp_server) or die("Could not connect to $ftp_server");
$login = ftp_login($ftp_conn, $ftp_username, $ftp_userpass);
// get system type
if ($type = ftp_systype($ftp_conn))
{
echo "System type is: $type";
}
else
{
echo "Could not get system type.";
}
// close connection
ftp_close($ftp_conn);
?>
L'output potrebbe assomigliare a questo:
System type is: UNIX
Definizione e utilizzo
La funzione ftp_systype() restituisce l'identificatore del tipo di sistema del server FTP.
Sintassi
ftp_systype(ftp_conn);
Valori dei parametri
Parameter | Description |
---|---|
ftp_conn | Required. Specifies the FTP connection to use |
Dettagli tecnici
Valore di ritorno: | Il tipo di sistema in caso di successo, FALSE in caso di errore |
---|---|
Versione PHP: | 4+ |
❮ Riferimento FTP PHP