Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

php image detection

Posted on 2011-10-28
1
Medium Priority
?
220 Views
Last Modified: 2012-05-12

Hello Everybody,

My aim is to properly identify images url.  There are many urls that does not have an image extension like "http://open.thumbshots.org/image.pxf?url=http://en.wikipedia.org/wiki/Poodle".

I need to identify this url is an image. How it is possible?.
0
Comment
Question by:jacobbbc
1 Comment
 
LVL 11

Accepted Solution

by:
kelvinwkw earned 2000 total points
ID: 37043523
this will help

list($width, $height, $type, $attr) = getimagesize("http://open.thumbshots.org/image.pxf?url=http://en.wikipedia.org/wiki/Poodle");
echo image_type_to_mime_type ($type)."\n";


0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses how to create an extensible mechanism for linked drop downs.
Many old projects have bad code, but the budget doesn't exist to rewrite the codebase. You can update this code to be safer by introducing contemporary input validation, sanitation, and safer database queries.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
Suggested Courses

564 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question