xref: /PHP-8.1/ext/ftp/tests/ftp_set_option.phpt (revision e9f783fc)
1--TEST--
2Testing ftp_set_option basic functionality
3--CREDITS--
4Gabriel Caruso (carusogabriel34@gmail.com)
5--EXTENSIONS--
6ftp
7pcntl
8--FILE--
9<?php
10require 'server.inc';
11
12$ftp = ftp_connect('127.0.0.1', $port);
13ftp_login($ftp, 'user', 'pass');
14$ftp or die("Couldn't connect to the server");
15
16var_dump(ftp_set_option($ftp, FTP_TIMEOUT_SEC, 10));
17var_dump(ftp_set_option($ftp, FTP_AUTOSEEK, false));
18var_dump(ftp_set_option($ftp, FTP_USEPASVADDRESS, true));
19?>
20--EXPECT--
21bool(true)
22bool(true)
23bool(true)
24