jeudi 2 avril 2015

Detect if image is embedded

I started to write my own image host but I have a little problem: I want to display an HTML page if you directly view the link (eg. Domain.com/img/123) via the browser, and an image if you embed the link via





<img src="Domain.com/img/123">


to faciliate the use.


Is this possible to detect whether the link is directly viewed or the link is embedded with PHP?


Thank you!


Aucun commentaire:

Enregistrer un commentaire