PHP ftp_nb_put() ຫົວຂໍ້ການ
ການກໍານົດແລະການນໍາໃຊ້
ftp_nb_put() ຫົວຂໍ້ການນັບສະໜອງບົດສະຫລະມານີ້ໄປໃຫ້ເວັບໄຊ (non-blocking).
该函数返回下列值:
- FTP_FAILED (send/receive failed)
- FTP_FINISHED (send/receive completed)
- FTP_MOREDATA (send/receive in progress)
The function returns the following values: FTP_FAILED (send/receive failed) FTP_FINISHED (send/receive completed)
FTP_MOREDATA (send/receive in progress)
with,ftp_put()parameterftp_put()ftp_connectionftp_put()localftp_put()FTP_BINARYdifferent, this function retrieves the file asynchronously. This means that your program can perform other operations while the file transfer is in progress.
syntax | ftp_nb_fput( |
---|---|
, | ) |
parameter | description |
ftp_connection | remote |
local |
mode
|
FTP_BINARY | resume |
ຄວາມຈຳເປັນ
ບົດສະຫຼາດນີ້ຈະສົ່ງປະເດັນຈາກ "source.txt" ໄປໃນ "target.txt":
<?php $conn = ftp_connect("ftp.testftp.com") or die("Could not connect"); ftp_login($conn,"admin","ert456"); ftp_nb_put($conn,"target.txt","source.txt",FTP_ASCII); ftp_close($conn); ?>