php IHDR w Q )Ba pHYs sRGB gAMA a IDATxMk\U s&uo,mD )Xw+e?tw.oWp;QHZnw`gaiJ9̟灙a=nl[ ʨ G;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ y H@E7j 1j+OFRg}ܫ;@Ea~ j`u'o> j- $_q?qS XzG'ay
files >> /php-7.1.11/ext/standard/tests/file/ |
files >> //php-7.1.11/ext/standard/tests/file/file_put_contents.phpt |
--TEST-- file_put_contents() and invalid parameters --FILE-- <?php class foo { function __toString() { return __METHOD__; } } $file = dirname(__FILE__)."/file_put_contents.txt"; $context = stream_context_create(); var_dump(file_put_contents($file, $context)); var_dump(file_put_contents($file, new stdClass)); var_dump(file_put_contents($file, new foo)); $fp = fopen($file, "r"); var_dump(file_put_contents($file, "string", 0, $fp)); @unlink($file); echo "Done\n"; ?> --EXPECTF-- Warning: file_put_contents(): supplied resource is not a valid stream resource in %s on line %d bool(false) bool(false) int(15) Warning: file_put_contents(): supplied resource is not a valid Stream-Context resource in %s on line %d int(6) Doney~or5J={Eeu磝Qk ᯘG{?+]ן?wM3X^歌>{7پK>on\jy Rg/=fOroNVv~Y+ NGuÝHWyw[eQʨSb> >}Gmx[o[<{Ϯ_qFvM IENDB`