Home
last modified time | relevance | path

Searched refs:file (Results 101 – 125 of 1763) sorted by relevance

12345678910>>...71

/PHP-5.3/ext/standard/tests/file/
H A Dfopen_variation11-win32.phpt17 * Description: Open a file or a URL and return a file pointer
49 $thirdfile = 'c:\\'.$file;
89 file in root
92 file in root
97 file not opened for read
104 file not opened for read
111 file not opened for read
121 file not opened for read
126 file in root
138 file in fopen11.tmpDir
[all …]
H A Dfwrite_variation3-win32.phpt23 include ("file.inc");
70 // close the file, get the size and content of the file.
86 -- Opening file in a --
98 -- Opening file in ab --
110 -- Opening file in at --
122 -- Opening file in a+ --
160 -- Opening file in a --
172 -- Opening file in ab --
184 -- Opening file in at --
234 -- Opening file in a --
[all …]
H A Dfwrite_variation3.phpt23 include ("file.inc");
71 // close the file, get the size and content of the file.
87 -- Opening file in a --
99 -- Opening file in ab --
111 -- Opening file in at --
123 -- Opening file in a+ --
161 -- Opening file in a --
173 -- Opening file in ab --
185 -- Opening file in at --
235 -- Opening file in a --
[all …]
H A Dfread_basic.phpt13 // include the file.inc for common functions for test
14 include ("file.inc");
33 test fread with file opened in "r" and "rb" mode only
53 echo "Error: failed to fopen() file: $filename!";
71 /* read file by giving size more than its size */
83 // reading 1000 bytes within the file max size
94 var_dump(fclose($file_handle)); // now close the file
97 // delete the file created
98 delete_file($filename); // delete file with name
109 Reading 1024 bytes from file, expecting 1024 bytes ... OK
[all …]
H A Dfgetcsv_variation11.phpt48 echo "Error: failed to create file $filename!\n";
62 // else rewind the file pointer to begining of the file
67 // rewind the file pointer to bof
80 // check the file pointer position and if eof
84 // close the file
86 //delete file
96 -- Testing fgetcsv() with file opened using r mode --
106 -- Testing fgetcsv() with file opened using rb mode --
116 -- Testing fgetcsv() with file opened using rt mode --
126 -- Testing fgetcsv() with file opened using r+ mode --
[all …]
H A D007_variation21.phpt9 Description: Opens file or URL.
14 Description: Closes an open file pointer
17 /* Test fopen() and fclose(): Opening the file in "ab" 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_variation21.tmp";
30 $file_handle = fopen($file, "ab"); //opening the file "ab" mode
41 unlink($file); //Deleting the file
42 fclose( fopen($file, "ab") ); //Opening the non-existing file in "ab" mode, which will be created
[all …]
H A D007_variation22.phpt9 Description: Opens file or URL.
14 Description: Closes an open file pointer
17 /* Test fopen() and fclose(): Opening the file in "a+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_variation22.tmp";
30 $file_handle = fopen($file, "a+b"); //opening the file "a+b" mode
40 unlink($file); //Deleting the file
41 fclose( fopen($file, "a+b") ); //Opening the non-existing file in "a+b" mode, which will be created
[all …]
H A D007_variation14.phpt9 Description: Opens file or URL.
14 Description: Closes an open file pointer
17 /* Test fopen() and fclose(): Opening the file in "a+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_variation14.tmp";
30 $file_handle = fopen($file, "a+t"); //opening the file "a+t" mode
40 unlink($file); //Deleting the file
41 fclose( fopen($file, "a+t") ); //Opening the non-existing file in "a+t" mode, which will be created
[all …]
H A D007_variation5.phpt9 Description: Opens file or URL.
14 Description: Closes an open file pointer
17 /* Test fopen() and fclose(): Opening the file in "a" 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_variation5.tmp";
30 $file_handle = fopen($file, "a"); //opening the file "a" mode
41 unlink($file); //Deleting the file
42 fclose( fopen($file, "a") ); //Opening the non-existing file in "a" mode, which will be created
[all …]
H A D007_variation6.phpt9 Description: Opens file or URL.
14 Description: Closes an open file pointer
17 /* Test fopen() and fclose(): Opening the file in "a+" 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_variation6.tmp";
30 $file_handle = fopen($file, "a+"); //opening the file "a+" mode
40 unlink($file); //Deleting the file
41 fclose( fopen($file, "a+") ); //Opening the non-existing file in "a+" mode, which will be created
[all …]
H A Dcopy_variation13.phpt6 Description: Makes a copy of the file source to dest.
10 /* Test copy(): Trying to copy dir to an existing file */
14 $file = $file_path."/copy_variation13_dir.tmp";
15 fclose(fopen($file, "w"));
19 echo "*** Testing copy() in copying dir to file ***\n";
20 var_dump( copy($dir, $file) );
22 var_dump( file_exists($file) );
28 var_dump( is_file($file) );
29 var_dump( is_dir($file) );
31 var_dump( filesize($file) );
[all …]
H A Dfgetcsv_variation15.phpt43 echo "Error: failed to create file $filename!\n";
56 // else rewind the file pointer to begining of the file
61 // rewind the file pointer to bof
70 // check the file pointer position and if eof
74 // close the file
76 //delete file
86 -- Testing fgetcsv() with file opened using r mode --
96 -- Testing fgetcsv() with file opened using rb mode --
106 -- Testing fgetcsv() with file opened using rt mode --
116 -- Testing fgetcsv() with file opened using r+ mode --
[all …]
H A Dfgetcsv_variation16.phpt45 echo "Error: failed to create file $filename!\n";
58 // else rewind the file pointer to begining of the file
63 // rewind the file pointer to bof
74 // check the file pointer position and if eof
78 // close the file
80 //delete file
90 -- Testing fgetcsv() with file opened using r mode --
100 -- Testing fgetcsv() with file opened using rb mode --
110 -- Testing fgetcsv() with file opened using rt mode --
120 -- Testing fgetcsv() with file opened using r+ mode --
[all …]
H A Dfwrite_variation1-win32.phpt23 include ("file.inc");
62 // move the file pointer to end of the file and try fwrite()
85 -- Opening file in r --
97 -- Opening file in rb --
109 -- Opening file in rt --
123 -- Opening file in r --
135 -- Opening file in rb --
147 -- Opening file in rt --
161 -- Opening file in r --
173 -- Opening file in rb --
[all …]
H A Dfwrite_variation1.phpt23 include ("file.inc");
61 // move the file pointer to end of the file and try fwrite()
83 -- Opening file in r --
95 -- Opening file in rb --
107 -- Opening file in rt --
121 -- Opening file in r --
133 -- Opening file in rb --
145 -- Opening file in rt --
159 -- Opening file in r --
171 -- Opening file in rb --
[all …]
H A Dfgetss_variation5-win32.phpt55 // rewind the file pointer to begining of the file
74 // close the file
77 // delete the file
91 -- Reading when file pointer points to EOF --
106 -- Reading when file pointer points to EOF --
121 -- Reading when file pointer points to EOF --
136 -- Reading when file pointer points to EOF --
151 -- Reading when file pointer points to EOF --
166 -- Reading when file pointer points to EOF --
181 -- Reading when file pointer points to EOF --
[all …]
H A Dfgetss_variation5.phpt52 // rewind the file pointer to begining of the file
71 // close the file
74 // delete the file
88 -- Reading when file pointer points to EOF --
103 -- Reading when file pointer points to EOF --
118 -- Reading when file pointer points to EOF --
133 -- Reading when file pointer points to EOF --
148 -- Reading when file pointer points to EOF --
163 -- Reading when file pointer points to EOF --
178 -- Reading when file pointer points to EOF --
[all …]
H A Dfile_variation4.phpt2 Test file() function : third parameter variation
5 /* Prototype : array file(string filename [, int flags[, resource context]])
6 * Description: Read entire file into an array
7 * Source code: ext/standard/file.c
11 echo "*** Testing file() : usage variation ***\n";
55 // create a file stream resource
111 // file stream resource
112 'file stream resource' => $file_stream_resource,
119 var_dump( file($filename, $flags, $value) );
129 *** Testing file() : usage variation ***
[all …]
H A Dfilesize_variation4-win32.phpt2 Test filesize() function: usage variations - file mode & holes in file
17 require($file_path."/file.inc");
20 …** Testing filesize() with data written using different file modes and by creating holes in file *…
40 echo "-- opening the file in 'a' mode, adding data and checking the file --\n";
47 echo "-- opening the file in 'at' mode, adding data and checking the file --\n";
73 echo "-- with empty file --\n";
89 *** Testing filesize() with data written using different file modes and by creating holes in file *…
96 -- opening the file in 'a' mode, adding data and checking the file --
98 -- opening the file in 'at' mode, adding data and checking the file --
105 -- opening the existing file in write mode --
[all …]
H A Dfgetcsv_variation10.phpt2 Test fgetcsv() : usage variations - file pointer pointing to EOF
10 /* Testing fgetcsv() by reading from a file when the file pointer is pointing to end of file */
47 echo "Error: failed to create file $filename!\n";
61 // else rewind the file pointer to begining of the file
68 // set the file pointer to EOF
73 // now file pointer should point to end of the file, try reading again
76 // check the file pointer position and if eof
80 // check the file pointer position and if eof
84 // close the file
86 //delete file
[all …]
H A D007_variation8.phpt9 Description: Opens file or URL.
14 Description: Closes an open file pointer
17 /* Test fopen() and fclose(): Opening the file in "x+" mode,
18 checking for the file creation, write & read operations,
19 checking for the file pointer position,
20 checking for the warning msg when trying to open an existing file in "x+" mode,
25 $file = $file_path."/007_variation8.tmp";
28 $file_handle = fopen($file, "x+"); //opening the non-existing file in "x+" mode, file will be crea…
31 var_dump( ftell($file_handle) ); //Initial file pointer position, expected at the begining of the
37 var_dump( fclose($file_handle) ); //Check for close operation on the file handle
[all …]
/PHP-5.3/ext/spl/tests/
H A DSplFileObject_fwrite_variation_003.phpt6 $file = dirname(__FILE__).'/SplFileObject_fwrite_variation_002.txt';
7 if(file_exists($file)) {
8 unlink($file);
10 $obj = New SplFileObject($file,'w');
12 var_dump(file_get_contents($file));
16 $file = dirname(__FILE__).'/SplFileObject_fwrite_variation_002.txt';
17 if(file_exists($file)) {
18 unlink($file);
/PHP-5.3/ext/gd/tests/
H A D001.phpt2 imagecreatefrompng() and empty/missing file
8 $file = dirname(__FILE__)."/001.test";
9 @unlink($file);
11 var_dump(imagecreatefrompng($file));
12 touch($file);
13 var_dump(imagecreatefrompng($file));
15 @unlink($file);
20 Warning: imagecreatefrompng(%s001.test): failed to open stream: No such file or directory in %s on …
23 Warning: imagecreatefrompng(): '%s001.test' is not a valid PNG file in %s on line %d
/PHP-5.3/ext/pdo_mysql/tests/
H A Dpdo_mysql___construct_uri.phpt17 $file = $tmp . DIRECTORY_SEPARATOR . 'pdomuri.tst';
21 $uri = sprintf('uri:file:%s', $file);
23 if ($fp = @fopen($file, 'w')) {
24 // ok, great we can create a file with a DSN in it
28 assert(file_exists($file));
34 $file, filesize($file), file_get_contents($file),
37 unlink($file);
40 if ($fp = @fopen($file, 'w')) {
45 assert(file_exists($file));
51 $file, filesize($file), file_get_contents($file),
[all …]
/PHP-5.3/ext/zlib/tests/
H A Dgzfile_variation15.phpt33 gzwrite($h, "This is a file in dir2");
36 // should read dir2 file
40 //create a file in dir1
42 gzwrite($h, "This is a file in dir1");
45 //should now read dir1 file
49 // create a file in working directory
54 //should still read dir1 file
70 //should read the file in script dir
85 string(22) "This is a file in dir2"
90 string(22) "This is a file in dir1"
[all …]

Completed in 42 milliseconds

12345678910>>...71