1--TEST--
2Test vfprintf() function : basic functionality - char format
3--FILE--
4<?php
5echo "*** Testing vfprintf() : basic functionality - using char format ***\n";
6
7// Initialise all required variables
8$format = "format";
9$format1 = "%c";
10$format2 = "%c %c";
11$format3 = "%c %c %c";
12$arg1 = array(65);
13$arg2 = array(65,66);
14$arg3 = array(65,66,67);
15
16/* creating dumping file */
17$data_file = __DIR__ . '/vfprintf_basic5.txt';
18if (!($fp = fopen($data_file, 'wt')))
19   return;
20
21vfprintf($fp, $format1,$arg1);
22fprintf($fp, "\n");
23
24vfprintf($fp, $format2,$arg2);
25fprintf($fp, "\n");
26
27vfprintf($fp, $format3,$arg3);
28fprintf($fp, "\n");
29
30fclose($fp);
31print_r(file_get_contents($data_file));
32
33unlink($data_file);
34?>
35--EXPECT--
36*** Testing vfprintf() : basic functionality - using char format ***
37A
38A B
39A B C
40