Query: vfprintf
OS: php
Section: 3
Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar
VFPRINTF(3) 1 VFPRINTF(3) vfprintf - Write a formatted string to a streamSYNOPSISint vfprintf (resource $handle, string $format, array $args)DESCRIPTIONWrite a string produced according to $format to the stream resource specified by $handle. Operates as fprintf(3) but accepts an array of arguments, rather than a variable number of arguments.PARAMETERSo $handle - o $format - See sprintf(3) for a description of $format. o $args -RETURN VALUESReturns the length of the outputted string.EXAMPLESExample #1 vfprintf(3): zero-padded integers <?php if (!($fp = fopen('date.txt', 'w'))) return; vfprintf($fp, "%04d-%02d-%02d", array($year, $month, $day)); // will write the formatted ISO date to date.txt ?>SEE ALSOprintf(3), sprintf(3), sscanf(3), fscanf(3), vsprintf(3), number_format(3). PHP Documentation Group VFPRINTF(3)