Lines Matching refs:file

2 Test symlink(), linkinfo(), link() and is_link() functions : usage variations - access/update file
15 Description: Tells whether the given file is a symbolic link.
24 /* Variation 3 : Create file and a soft link to the file
25 Access data of the file through the soft link
26 Update the file through soft link
27 Check size of file and soft link link
31 echo "*** Accessing and updating data of file through soft link ***\n";
32 // Creating file and inserting data into it
35 // create temp file
36 $file = fopen($filename, "w");
38 // create soft link to file
45 // fill data into file
46 fwrite($file, str_repeat("text", 20) );
47 fclose($file);
49 echo "\n-- Access data of the file through the soft link --\n";
53 echo "\n-- Check size of soft link and file --\n";
65 echo "\n-- Updating file with data through soft link --\n";
71 // now check temp file for data; it should append "Hello World"
75 echo "\n-- Check size of soft link and file --\n";
87 echo "\n-- Updating file with data and check data through soft link --\n";
88 // write to temp file
89 $file = fopen($filename, "w");
90 fwrite($file, "Hello World");
91 fclose($file);
97 echo "\n-- Check size of soft link and file --\n";
111 // delete the temporary file
117 *** Accessing and updating data of file through soft link ***
120 -- Access data of the file through the soft link --
123 -- Check size of soft link and file --
129 -- Updating file with data through soft link --
132 -- Check size of soft link and file --
138 -- Updating file with data and check data through soft link --
141 -- Check size of soft link and file --