1--TEST-- 2imagecreatefromstring() - PNG format 3--SKIPIF-- 4<?php 5if (!extension_loaded('gd')) die('skip ext/gd required'); 6if (!(imagetypes() & IMG_PNG)) die('skip PNG support required'); 7?> 8--FILE-- 9<?php 10// create an image from a PNG string representation 11$im = imagecreatefromstring(file_get_contents(__DIR__ . '/imagecreatefromstring.gif')); 12var_dump(imagesx($im)); 13var_dump(imagesy($im)); 14 15?> 16===DONE=== 17--EXPECT-- 18int(10) 19int(10) 20===DONE=== 21