PHP handleiding

PHP TUIS PHP Inleiding PHP installeer PHP sintaksis PHP opmerkings PHP veranderlikes PHP Echo / Druk PHP datatipes PHP Strings PHP-nommers PHP Wiskunde PHP konstante PHP-operateurs PHP As...Anders...Elseif PHP skakelaar PHP-lusse PHP funksies PHP-skikkings PHP Superglobals PHP RegEx

PHP- vorms

PHP-vormhantering PHP-vorm validering PHP-vorm word vereis PHP-vorm URL/e-pos PHP-vorm voltooi

PHP Gevorderd

PHP datum en tyd PHP sluit in PHP-lêerhantering PHP-lêer oop/lees PHP-lêer skep/skryf PHP-lêer oplaai PHP-koekies PHP-sessies PHP filters PHP-filters Gevorderd PHP-terugbelfunksies PHP JSON PHP-uitsonderings

PHP OOP

PHP Wat is OOP PHP Klasse/Objekte PHP Konstrukteur PHP vernietiger PHP Toegangswysigers PHP erfenis PHP konstante PHP Abstrakte Klasse PHP-koppelvlakke PHP eienskappe PHP statiese metodes PHP Statiese Eienskappe PHP naamruimtes PHP Iterables

MySQL- databasis

MySQL-databasis MySQL Connect MySQL Skep DB MySQL Skep tabel MySQL Voeg data in MySQL Kry Laaste ID MySQL Voeg veelvuldige in MySQL voorberei MySQL Kies Data MySQL Waar MySQL Bestel deur MySQL verwyder data MySQL-opdateringsdata MySQL-limietdata

PHP XML

PHP XML-ontleders PHP SimpleXML-ontleder PHP SimpleXML - Kry PHP XML Expat PHP XML DOM

PHP - AJAX

AJAX Intro AJAX PHP AJAX-databasis AJAX XML AJAX Live Search AJAX-peiling

PHP voorbeelde

PHP voorbeelde PHP samesteller PHP vasvra PHP Oefeninge PHP-sertifikaat

PHP- verwysing

PHP Oorsig PHP Skikking PHP-kalender PHP datum PHP gids PHP fout PHP-uitsondering PHP lêerstelsel PHP filter PHP FTP PHP JSON PHP sleutelwoorde PHP Libxml PHP-pos PHP Wiskunde PHP Diverse PHP MySQLi PHP-netwerk PHP-uitsetbeheer PHP RegEx PHP SimpleXML PHP-stroom PHP-string PHP veranderlike hantering PHP XML-ontleder PHP zip PHP Tydsones

PHP FTP- funksies


PHP FTP Inleiding

Die FTP-funksies gee kliënt toegang tot lêerbedieners deur die File Transfer Protocol (FTP).

Die FTP-funksies word gebruik om verbindings oop te maak, aan te meld en toe te maak, asook om op te laai, af te laai, te hernoem, uit te vee en inligting oor lêers van lêerbedieners af te kry. Nie al die FTP-funksies sal met elke bediener werk of dieselfde resultate lewer nie. Die FTP-funksies het beskikbaar geword met PHP 3.

As jy net van 'n lêer op 'n FTP-bediener wil lees of na 'n lêer wil skryf, oorweeg dit om die ftp://-omhulsel te gebruik met die lêerstelsel-funksies wat 'n eenvoudiger en meer intuïtiewe koppelvlak bied.


Installasie

Vir hierdie funksies om te werk, moet jy PHP saamstel met --enable-ftp.

Die Windows-weergawe van PHP het ingeboude ondersteuning vir hierdie uitbreiding.


PHP FTP-funksies

Function Description
ftp_alloc() Allocates space for a file to be uploaded to the FTP server
ftp_cdup() Changes to the parent directory on the FTP server
ftp_chdir() Changes the current directory on the FTP server
ftp_chmod() Sets permissions on a file via FTP
ftp_close() Closes an FTP connection
ftp_connect() Opens an FTP connection
ftp_delete() Deletes a file on the FTP server
ftp_exec() Executes a command on the FTP server
ftp_fget() Downloads a file from the FTP server and saves it into an open local file
ftp_fput() Uploads from an open file and saves it to a file on the FTP server
ftp_get() Downloads a file from the FTP server
ftp_get_option() Returns runtime options of the FTP connection
ftp_login() Logs in to the FTP connection
ftp_mdtm() Returns the last modified time of a specified file
ftp_mkdir() Creates a new directory on the FTP server
ftp_mlsd() Returns the list of files in the specified directory
ftp_nb_continue() Continues retrieving/sending a file (non-blocking)
ftp_nb_fget() Downloads a file from the FTP server and saves it into an open file (non-blocking)
ftp_nb_fput() Uploads from an open file and saves it to a file on the FTP server (non-blocking)
ftp_nb_get() Downloads a file from the FTP server (non-blocking)
ftp_nb_put() Uploads a file to the FTP server (non-blocking)
ftp_nlist() Returns a list of files in the specified directory on the FTP server
ftp_pasv() Turns passive mode on or off
ftp_put() Uploads a file to the FTP server
ftp_pwd() Returns the current directory name
ftp_quit() Alias of ftp_close()
ftp_raw() Sends a raw command to the FTP server
ftp_rawlist() Returns a list of files with file information from a specified directory
ftp_rename() Renames a file or directory on the FTP server
ftp_rmdir() Deletes an empty directory on the FTP server
ftp_set_option() Sets runtime options for the FTP connection
ftp_site() Sends an FTP SITE command to the FTP server
ftp_size() Returns the size of the specified file
ftp_ssl_connect() Opens a secure SSL-FTP connection
ftp_systype() Returns the system type identifier of the FTP server

PHP Vooraf gedefinieerde FTP konstante

Constant Type Description
FTP_ASCII Integer  
FTP_AUTOSEEK Integer  
FTP_AUTORESUME Integer  
FTP_BINARY Integer  
FTP_FAILED Integer Asynchronous transfer has failed
FTP_FINISHED Integer Asynchronous transfer is completed
FTP_IMAGE Integer Alias of FTP_BINARY
FTP_MOREDATA Integer Asynchronous transfer is in progress
FTP_TEXT Integer Alias of FTP_ASCII
FTP_TIMEOUT_SEC Integer The timeout used for network operations
FTP_USEPASVADDRESS Boolean