php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #68499 getimagesize could support stream resources
Submitted: 2014-11-25 18:33 UTC Modified: 2016-08-01 02:30 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: christian at kitsunet dot com Assigned:
Status: Open Package: GetImageSize related
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: christian at kitsunet dot com
New email:
PHP Version: OS:

 

 [2014-11-25 18:33 UTC] christian at kitsunet dot com
Description:
------------
getimagesize() could support stream resources so the test script would actually work. The test script itself is rather pointless of course as you could argue that I could just use the http uri in getimagesize() which would work. But in case you have only the already opened stream it would be very convenient to have getimagesize work on that.

Test script:
---------------
<?php

// as described above this line is just to aquire a stream, as example
$resource = fopen('http://bugs.php.net/images/logo.gif', 'r');

$imagesize = getimagesize($resource);

var_dump($imagesize);

?>


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2016-08-01 02:30 UTC] kalle@php.net
-Package: GD related +Package: GetImageSize related
 
PHP Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Mon Oct 14 09:01:26 2019 UTC