Home
last modified time | relevance | path

Searched refs:file (Results 176 – 200 of 1994) sorted by relevance

12345678910>>...80

/PHP-7.4/ext/standard/tests/file/
H A Dstat_variation6-win32.phpt2 Test stat() functions: usage variations - changing permissions of dir/file
14 * Description: Gives information about a file
17 /* test the effects on the stats of dir/file for changing permissions of dir/file */
21 require "$file_path/file.inc";
24 /* create temp file and directory */
29 $file_handle = fopen($filename, "w"); // temp file
33 // checking stat() on file
34 echo "\n*** Testing stat() on file with miscelleneous file permission and content ***\n";
51 echo "\n*** Testing stat() on directory with miscelleneous file permission ***\n";
77 *** Testing stat() on file with miscelleneous file permission and content ***
[all …]
H A Dftruncate_variation7-win32.phpt13 Description: Truncates a file to a given length
16 /* truncate the file when file pointer is positioned at end of the file */
17 // include common file related test functions
18 include ("file.inc");
22 /* test ftruncate with file opened in different modes */
36 // create 1 file with some contents
39 // fopen the file using the $file_modes
44 // fopen the file using the $file_modes
48 echo "Error: failed to open file $filename!\n";
52 rewind($file_handle); // file pointer to 0
[all …]
H A Dftruncate_variation7.phpt13 Description: Truncates a file to a given length
16 /* truncate the file when file pointer is positioned at end of the file */
17 // include common file related test functions
18 include ("file.inc");
22 /* test ftruncate with file opened in different modes */
36 // create 1 file with some contents
39 // fopen the file using the $file_modes
44 // fopen the file using the $file_modes
48 echo "Error: failed to open file $filename!\n";
52 rewind($file_handle); // file pointer to 0
[all …]
H A Dfile_basic.phpt2 Test file() function : basic functionality
6 * Prototype: array file ( string filename [,int use-include_path [,resource context]] );
7 * Description: Reads entire file into an array
8 * Returns the file in an array
10 require(__DIR__ . '/file.inc');
12 echo "*** Testing file() with basic types of files ***\n";
17 print_r( file($file_path."/file_basic1.tmp") );
21 echo "*** Testing for return type of file() function ***\n";
24 $ret_arr = file($file_path."/file_basic1.tmp");
32 *** Testing file() with basic types of files ***
[all …]
H A Dfwrite_variation2-win32.phpt23 include ("file.inc");
78 /* display the file content, check the file size */
94 -- Opening file in r+ --
111 -- Opening file in r+b --
128 -- Opening file in r+t --
147 -- Opening file in r+ --
164 -- Opening file in r+b --
181 -- Opening file in r+t --
200 -- Opening file in r+ --
217 -- Opening file in r+b --
[all …]
H A Dfwrite_variation2.phpt23 include ("file.inc");
78 /* display the file content, check the file size */
93 -- Opening file in r+ --
110 -- Opening file in r+b --
127 -- Opening file in r+t --
146 -- Opening file in r+ --
163 -- Opening file in r+b --
180 -- Opening file in r+t --
199 -- Opening file in r+ --
216 -- Opening file in r+b --
[all …]
H A Dlstat_stat_variation13.phpt2 Test lstat() and stat() functions: usage variations - file opened using w and r mode
10 Description: Gives information about a file or symbolic link
13 Description: Gives information about a file
16 /* use stat on file created using "w" and "r" mode of fopen */
19 require "$file_path/file.inc";
24 echo "*** Checking stat() on a file opened using read/write mode ***\n";
25 $file_handle = fopen($filename, "w"); // create file
31 // opening file again in read mode
32 $file_handle = fopen($filename, "r"); // read file
49 *** Checking stat() on a file opened using read/write mode ***
H A D007_variation10.phpt9 Description: Opens file or URL.
14 Description: Closes an open file pointer
17 /* Test fopen() and fclose(): Opening the file in "r+t" mode,
18 checking for the file creation, write & read operations,
19 checking for the file pointer position,
23 require($file_path."/file.inc");
26 $file = $file_path."/007_variation10.tmp";
30 $file_handle = fopen($file, "r+t"); //opening the file in "r+t" mode
33 var_dump( ftell($file_handle) ); //Initial file pointer position, expected at the beginning of the…
35 …ell($file_handle) ); //File pointer position after read operation, expected at the end of the file
[all …]
H A D007_variation18.phpt9 Description: Opens file or URL.
14 Description: Closes an open file pointer
17 /* Test fopen() and fclose(): Opening the file in "r+b" mode,
18 checking for the file creation, write & read operations,
19 checking for the file pointer position,
23 require($file_path."/file.inc");
26 $file = $file_path."/007_variation18.tmp";
30 $file_handle = fopen($file, "r+b"); //opening the file in "r+b" mode
33 var_dump( ftell($file_handle) ); //Initial file pointer position, expected at the beginning of the…
35 …ell($file_handle) ); //File pointer position after read operation, expected at the end of the file
[all …]
H A D007_variation2.phpt9 Description: Opens file or URL.
14 Description: Closes an open file pointer
17 /* Test fopen() and fclose(): Opening the file in "r+" mode,
18 checking for the file creation, write & read operations,
19 checking for the file pointer position,
23 require($file_path."/file.inc");
26 $file = $file_path."/007_variation2.tmp";
30 $file_handle = fopen($file, "r+"); //opening the file in "r+" mode
33 var_dump( ftell($file_handle) ); //Initial file pointer position, expected at the beginning of the…
35 …ell($file_handle) ); //File pointer position after read operation, expected at the end of the file
[all …]
H A Dfile_put_contents.phpt10 $file = __DIR__."/file_put_contents.txt";
14 var_dump(file_put_contents($file, $context));
15 var_dump(file_put_contents($file, new stdClass));
16 var_dump(file_put_contents($file, new foo));
17 $fp = fopen($file, "r");
18 var_dump(file_put_contents($file, "string", 0, $fp));
20 @unlink($file);
H A Dstat_variation3-win32.phpt2 Test stat() functions: usage variations - effects of creating/deleting the dir/file
14 * Description: Gives information about a file
17 /* test the effects of creating & deleting of subdir/file on the stats of dir/file */
20 require "$file_path/file.inc";
23 /* create temp file and directory */
26 echo "*** Testing stat(): with creating & deleting subdir/file ***\n";
29 echo "-- Testing stat() on dir after subdir and file is created in it --\n";
51 // comparing stats after the deletion of subdir and file
68 *** Testing stat(): with creating & deleting subdir/file ***
69 -- Testing stat() on dir after subdir and file is created in it --
[all …]
H A Dlstat_stat_variation21.phpt13 Description: Gives information about a file or symbolic link
16 Description: Gives information about a file
19 /* test the effects of truncate() on stats of a file */
22 require "$file_path/file.inc";
25 /* create temp file */
27 $fp = fopen($filename, "w"); // temp file
30 /* ftruncate the current file and check stat() on the file */
32 echo "*** Testing stat() on file by truncating it to given size ***\n";
37 // opening file in r/w mode
58 *** Testing stat() on file by truncating it to given size ***
H A Dfilestat.phpt2 various file stat func tests
24 var_dump(fileinode("/no/such/file/or/dir"));
25 var_dump(fileowner("/no/such/file/or/dir"));
26 var_dump(filegroup("/no/such/file/or/dir"));
27 var_dump(fileatime("/no/such/file/or/dir"));
28 var_dump(filectime("/no/such/file/or/dir"));
49 Warning: fileinode(): stat failed for /no/such/file/or/dir in %s on line %d
52 Warning: fileowner(): stat failed for /no/such/file/or/dir in %s on line %d
55 Warning: filegroup(): stat failed for /no/such/file/or/dir in %s on line %d
58 Warning: fileatime(): stat failed for /no/such/file/or/dir in %s on line %d
[all …]
H A Dfputcsv_variation13.phpt63 //close the file
69 //delete file
79 -- file opened in r+ --
88 -- file opened in r+b --
97 -- file opened in r+t --
106 -- file opened in a+ --
115 -- file opened in a+b --
133 -- file opened in w+ --
160 -- file opened in x+ --
187 -- file opened in r+ --
[all …]
/PHP-7.4/ext/spl/tests/
H A DDirectoryIterator_getExtension_basic.phpt12 foreach ($files as $file) {
13 touch($dir . $file);
19 foreach (new DirectoryIterator($dir) as $file) {
20 if ($file->isDot()) {
24 $dit_exts[] = $file->getExtension();
25 $nfo_exts[] = pathinfo($file->getFilename(), PATHINFO_EXTENSION);
35 foreach ($files as $file) {
36 unlink($dir . $file);
/PHP-7.4/ext/opcache/tests/
H A Dbug65559.phpt11 $file = __DIR__ . "/bug6559.inc.php";
12 file_put_contents($file, '<?php return 1;');
13 $var = include $file;
15 file_put_contents($file, '<?php return 2;');
16 $var = include $file;
18 @unlink($file);
/PHP-7.4/ext/standard/tests/dir/
H A Dreaddir_basic.phpt16 // include the file.inc for Function: function create_files()
18 include(__DIR__."/../file/file.inc");
27 while( FALSE !== ($file = readdir($dh)) ) {
28 $a[] = $file;
31 foreach($a as $file) {
32 var_dump($file);
38 while( FALSE !== ( $file = readdir() ) ) {
39 $a[] = $file;
42 foreach($a as $file) {
43 var_dump($file);
H A Dreaddir_basic-win32-mb.phpt22 // include the file.inc for Function: function create_files()
24 include(__DIR__."/../file/file.inc");
33 while( FALSE !== ($file = readdir($dh)) ) {
34 $a[] = $file;
37 foreach($a as $file) {
38 var_dump($file);
44 while( FALSE !== ( $file = readdir() ) ) {
45 $a[] = $file;
48 foreach($a as $file) {
49 var_dump($file);
/PHP-7.4/ext/phar/phar/
H A Dphar.php35 function command_include($file) argument
37 $file = 'phar://' . __FILE__ . '/' . $file;
38 if (file_exists($file)) {
39 include($file);
/PHP-7.4/ext/standard/tests/file/windows_mb_path/
H A Dtest_readdir_mb_names.phpt47 echo "filename: $file : filetype: " . filetype($dirw . $file) . "\n";
64 filename: Röd_Statistics.txt : filetype: file
65 filename: tschüß : filetype: file
67 filename: Voláçao : filetype: file
69 filename: českýtestování.inc : filetype: file
70 filename: š.txt : filetype: file
72 filename: żółć.txt : filetype: file
73 filename: Ελλάδα.txt : filetype: file
74 filename: привет : filetype: file
76 filename: テストマルチバイト・パス : filetype: file
[all …]
H A Dbug75063_utf8.phpt2 Bug #75063 Many filesystem-related functions do not work with multibyte file names, UTF-8
15 /* This file is in UTF-8. */
40 while ((\$file = readdir(\$dh)) !== false) {
41 if ("." == \$file || ".." == \$file) continue;
42 var_dump(\$file);
63 foreach ($obj as $file) {
64 if ("." == $file || ".." == $file) continue;
65 unlink($d0 . DIRECTORY_SEPARATOR . $file);
/PHP-7.4/ext/pdo_mysql/tests/
H A Dpdo_mysql_stmt_blobfromsteam.phpt14 $fp = fopen($file, 'w');
24 if (!file_exists($file))
27 unlink($file);
35 @unlink($file);
37 if (file_exists($file)) {
42 $fp = fopen($file, 'w');
44 printf("[%03d + 2] Cannot create test file '%s'\n", $offset, $file);
50 if (!file_exists($file)) {
51 printf("[%03d + 3] Failed to create test file '%s'\n", $offset, $file);
64 $fp = fopen($file, 'r');
[all …]
/PHP-7.4/ext/standard/tests/image/
H A Diptcembed_001.phpt2 iptcembed() and wrong file
6 $file = __DIR__.'/iptcembed_001.data';
7 $fp = fopen($file, "w");
11 var_dump(iptcembed(-1, $file, -1));
12 unlink($file);
/PHP-7.4/ext/openssl/tests/
H A Dopenssl_error_string_basic.phpt51 // common output file
55 // invalid file for is the test dir as writting file to existing dir should alway fail
57 // crt file
59 // csr file
61 // public key file
63 // private key file
98 // file for pkey (file:///) fails when opennig (BIO_new_file)
104 // file to export cannot be written
126 // file for x509 (file:///) fails when opennig (BIO_new_file)
132 // file to export cannot be written
[all …]

Completed in 56 milliseconds

12345678910>>...80