2 /* Prototype : int vfprintf ( resource $handle , string $format , array $args )
3 * Description: Write a formatted string to a stream
4 * Source code: ext/standard/formatted_print.c
7 echo "*** Testing vfprintf() : basic functionality - using unsigned format ***\n";
9 // Initialise all required variables
13 $format3 = "%u %u %u";
15 $arg2 = array(-1111,-1234567);
16 $arg3 = array(-1111,-1234567,-2345432);
18 /* creating dumping file */
19 $data_file = dirname(__FILE__
) . '/vfprintf_basic7.phpt.txt';
20 if (!($fp = fopen($data_file, 'wt')))
23 vfprintf($fp, $format1,$arg1);
26 vfprintf($fp, $format2,$arg2);
29 vfprintf($fp, $format3,$arg3);
33 print_r(file_get_contents($data_file));