0

I create a png image in the memory ,the code like this

rrdtool_function_graph(605,0,$graph_data_array)

when I run this

print rrdtool_function_graph(605,0,$graph_data_array)

It will show the png image. the question is ,how to convert it to the image file ,like abc.png ,with php?

4

1 回答 1

0

您可以使用 PHPfwrite来实现这一点

$handle = fopen('abc.png', 'w');
fwrite($handle , rrdtool_function_graph(605,0,$graph_data_array));
fclose($handle);
于 2012-08-22T11:58:06.990 回答