Home
last modified time | relevance | path

Searched refs:file (Results 226 – 250 of 1891) sorted by relevance

12345678910>>...76

/PHP-5.3/ext/standard/tests/file/
H A Dlstat_stat_variation11.phpt13 Description: Gives information about a file or symbolic link
16 Description: Gives information about a file
20 require "$file_path/file.inc";
22 /* test the effects of is_file() on stats of a file */
24 /* create temp file */
26 $fp = fopen($filename, "w"); // temp file
29 // is_file() on a file
30 echo "*** Testing stat() on a file after using is_file() on it ***\n";
54 *** Testing stat() on a file after using is_file() on it ***
H A Dlstat_stat_variation16.phpt2 Test lstat() and stat() functions: usage variations - effects changing permissions of file
13 Description: Gives information about a file or symbolic link
16 Description: Gives information about a file
19 /* test the effects on stats with changing permissions of file */
22 require "$file_path/file.inc";
25 $fp = fopen($filename, "w"); // temp file
28 // checking stat() on file after changing its permission
29 echo "*** Testing lstat() on a file after changing its access permission ***\n";
52 *** Testing lstat() on a file after changing its access permission ***
H A Dbug53848.phpt5 $file = dirname(__FILE__) . "/bug39538.csv";
6 @unlink($file);
7 file_put_contents($file, "a,b\n c, d");
8 $fp = fopen($file, "r");
11 @unlink($file);
H A Dstat_variation4-win32.phpt14 * Description: Gives information about a file
17 /* test the effects on the stats of dir/file for using is_dir() & is_file() on dir/file */
20 require "$file_path/file.inc";
23 /* create temp file and directory */
26 $file_handle = fopen("$file_path/stat_variation4.tmp", "w"); // temp file
30 echo "\n*** Testing stat(): on file and directory after accessing it
52 // is_file() on a file
53 echo "-- Testing on file --\n";
79 *** Testing stat(): on file and directory after accessing it
86 -- Testing on file --
H A Dfile_variation5-win32.phpt2 file() with various paths
23 echo "file() on a path containing .. and .\n";
24 var_dump(file("./$test_dirname/../$filename"));
27 var_dump(file("./$test_dirname/bad_dir/../../$filename"));
31 var_dump(file("../$filename"));
40 file() on a path containing .. and .
52 file() on a path containing .. with invalid directories
64 file() on a relative path from a different working directory
H A Dstat_variation8-win32.phpt14 * Description: Gives information about a file
17 /* test the effects of truncate() on stats of file */
21 require "$file_path/file.inc";
24 /* create temp file and directory */
27 $file_handle = fopen($filename, "w"); // temp file
31 echo "\n*** Testing stat(): on file by truncating it to given size ***\n";
33 // create temp file
42 // opening file in r/w mode
70 *** Testing stat(): on file by truncating it to given size ***
H A Dfile_put_contents_variation9.phpt12 /* Prototype : int file_put_contents(string file, mixed data [, int flags [, resource context]])
13 * Description: Write/Create a file with contents data and return the number of bytes written
14 * Source code: ext/standard/file.c
26 // link files even though it original file doesn't exist yet
35 //can only create a hardlink if the file exists.
46 function run_test($file) {
49 var_dump(file_put_contents($file, $data));
50 var_dump(file_put_contents($file, $extra, FILE_APPEND));
51 readfile($file);
H A Dfopen_variation16.phpt2 Test fopen() function : variation: use include path create and read a file (relative)
8 * Description: Open a file or a URL and return a file pointer
9 * Source code: ext/standard/file.c
43 fwrite($h, (binary) "This is the test file");
57 echo "could not find file for reading\n";
60 echo "found file - not in dir1\n";
72 found file - not in dir1
74 found file - not in dir1
H A Dfopen_variation17.phpt2 Test fopen() function : variation: use include path create and read a file (relative)
8 * Description: Open a file or a URL and return a file pointer
9 * Source code: ext/standard/file.c
42 fwrite($h, (binary) "This is the test file");
56 echo "could not find file for reading\n";
59 echo "found file for reading\n";
71 found file for reading
73 found file for reading
H A Dis_file_variation4.phpt6 Description: Tells whether the filename is a regular file
7 Returns TRUE if the filename exists and is a regular file
10 /* Passing file names with different notations, using slashes, wild-card chars */
14 echo "*** Testing is_file() with different notations of file names ***\n";
23 /* Testing a file trailing slash */
26 /* Testing file with double slashes */
39 foreach($files_arr as $file) {
41 var_dump( is_file( $file_path."/".$file ) );
56 *** Testing is_file() with different notations of file names ***
H A Drename_variation3-win32.phpt12 Description: Renames a file or directory
15 require dirname(__FILE__).'/file.inc';
22 /* test rename() by trying to rename an existing file/dir to the same name
32 echo "\n-- Renaming file to same file name --\n";
40 echo "\n-- Renaming existing file to existing directory name --\n";
45 echo "\n-- Renaming existing directory to existing file name --\n";
64 -- Renaming file to same file name --
72 -- Renaming existing file to existing directory name --
79 -- Renaming existing directory to existing file name --
H A Drename_variation5.phpt18 //create a file
29 echo "\n-- Renaming file to same file name --\n";
37 echo "\n-- Renaming existing link to existing file name --\n";
40 echo "\n-- Renaming existing file to existing directory name --\n";
42 echo "\n-- Renaming existing file to existing link name --\n";
45 echo "\n-- Renaming existing directory to existing file name --\n";
65 -- Renaming file to same file name --
76 -- Renaming existing link to existing file name --
79 -- Renaming existing file to existing directory name --
84 -- Renaming existing file to existing link name --
[all …]
/PHP-5.3/ext/dba/
H A Ddba_cdb.c54 php_stream *file; member
57 int file; member
66 php_stream* file = 0; in DBA_OPEN_FUNC() local
69 int file = 0; in DBA_OPEN_FUNC()
78 file = info->fp; in DBA_OPEN_FUNC()
81 if (file < 0) { in DBA_OPEN_FUNC()
90 file = info->fp; in DBA_OPEN_FUNC()
109 cdb_init(&cdb->c, file TSRMLS_CC); in DBA_OPEN_FUNC()
113 cdb_init(&cdb->c, file); in DBA_OPEN_FUNC()
115 cdb->file = file; in DBA_OPEN_FUNC()
[all …]
/PHP-5.3/ext/phar/tests/
H A Dphar_stub.phpt12 $file = '<?php echo "first stub\n"; __HALT_COMPILER(); ?>';
21 $file = '<?php echo "first stub\n"; __HALT_COMPILER(); ?>';
24 echo fread($fp, strlen($file)) . "\n";
27 $file = '<?php echo "second stub\n"; __HALT_COMPILER(); ?>';
30 $phar->setStub($file);
32 echo fread($fp, strlen($file)) . "\n";
38 fwrite($fp, $file);
47 echo fread($fp, strlen($file)) . "\n";
58 $phar->setStub($fp, strlen($file));
62 echo fread($fp, strlen($file)) . "\n";
[all …]
H A Dphar_copy.phpt17 $iname = '/file.txt';
79 file "notexisting" cannot be copied to file "another", file does not exist in %sphar_copy2.phar.php
80 file "a" cannot be copied to file "b", file must not already exist in phar %sphar_copy2.phar.php
82 file "d" cannot be copied to file ".phar/stub.php", cannot copy to Phar meta-file in %sphar_copy2.p…
83 file ".phar/stub.php" cannot be copied to file "d", cannot copy Phar meta-file in %sphar_copy2.phar…
/PHP-5.3/ext/standard/tests/general_functions/
H A Dbug41445_1.phpt6 $file = dirname(__FILE__)."/bug41445.ini";
19 file_put_contents($file, $data);
21 var_dump(parse_ini_file($file, TRUE));
22 var_dump(parse_ini_file($file));
24 @unlink($file);
/PHP-5.3/sapi/cgi/tests/
H A D002.phpt14 $file = dirname(__FILE__)."/002.test.php";
16 file_put_contents($file, '<?php var_dump(ini_get("max_execution_time")); ?>');
18 var_dump(`$php -n -d max_execution_time=111 $file`);
19 var_dump(`$php -n -d max_execution_time=500 $file`);
20 var_dump(`$php -n -d max_execution_time=500 -d max_execution_time=555 $file`);
22 file_put_contents($file, '<?php var_dump(ini_get("max_execution_time")); var_dump(ini_get("upload_t…
24 var_dump(`$php -n -d upload_tmp_dir=/test/path -d max_execution_time=555 $file`);
26 unlink($file);
/PHP-5.3/ext/zlib/tests/
H A Dgzopen_variation6.phpt2 Test gzopen() function : variation: relative/absolute file
12 * Description: Open a .gz-file and return a .gz-file pointer
22 gzwrite($h, "This is an absolute file");
26 gzwrite($h, "This is a relative file");
45 This is an absolute file
46 This is a relative file
/PHP-5.3/ext/spl/examples/
H A Dinigroups.inc3 /** @file inigroups.inc
16 * @brief Class to iterate all groups within an ini file.
20 * Using this class you can iterator over all groups of a ini file.
31 * Construct an ini file group iterator from a filename.
33 * @param file Ini file to open.
35 function __construct($file) {
36 parent::__construct(new DbaReader($file, 'inifile'), '^\[.*\]$');
H A Dphar_from_dir.php42 foreach($dir as $file)
44 echo "$file\n";
45 copy($file, "phar://newphar/$file");
/PHP-5.3/tests/basic/
H A Drfc1867_max_file_uploads_empty_files_debug.phpt13 Content-Type: text/plain-file
18 Content-Type: text/plain-file
23 Content-Type: text/plain-file
28 Content-Type: text/plain-file
41 Notice: No file uploaded in Unknown on line 0
43 Notice: No file uploaded in Unknown on line 0
45 Warning: Uploaded file size 0 - file [file4=file4.txt] not saved in Unknown on line 0
91 string(15) "text/plain-file"
/PHP-5.3/ext/standard/tests/strings/
H A Dsha1_file.phpt7 * Description: Calculate the sha1 hash of a file
12 /* Creating an empty file */
16 /* Creating a data file */
20 /* Writing into file */
22 $content = b"Add this to the file\n";
25 echo "Cannot write to file ($filename)";
58 echo "\n-- Raw Binary Output for Empty file as Argument --\n";
108 -- Hexadecimal Output for Empty file as Argument --
111 -- Raw Binary Output for Empty file as Argument --
114 -- Hexadecimal Output for a valid file with some contents --
[all …]
/PHP-5.3/ext/standard/tests/url/
H A Durls.inc33 'http://www.php.net:80/this/is/a/very/deep/directory/../file.php',
57 'zlib:/path/to/my/file/file.txt',
63 'file:///path/to/file',
64 'file://path/to/file',
65 'file:/path/to/file',
81 'file:///:',
82 'file:///a:/',
83 'file:///ab:/',
84 'file:///a:/',
85 'file:///@:/',
[all …]
H A Dparse_url_basic_007.phpt53 ….php.net:80/this/is/a/very/deep/directory/../file.php : string(42) "/this/is/a/very/deep/directo…
77 --> zlib:/path/to/my/file/file.txt : string(25) "/path/to/my/file/file.txt"
83 --> file:///path/to/file : string(13) "/path/to/file"
84 --> file://path/to/file : string(8) "/to/file"
85 --> file:/path/to/file : string(13) "/path/to/file"
101 --> file:///: : string(2) "/:"
102 --> file:///a:/ : string(3) "a:/"
103 --> file:///ab:/ : string(5) "/ab:/"
104 --> file:///a:/ : string(3) "a:/"
105 --> file:///@:/ : string(3) "@:/"
[all …]
/PHP-5.3/ext/xmlreader/tests/
H A D007.phpt11 $file = dirname(__FILE__) . '/__007.xml';
12 file_put_contents($file, $xmlstring);
15 $reader->open($file);
21 print "file relaxNG: ok\n";
23 print "file relaxNG: failed\n";
26 unlink($file);
53 file relaxNG: ok

Completed in 46 milliseconds

12345678910>>...76