With PHP you can create the headers at the top of the page, with python you can create a 'script' that sends custom headers to a server, thus you could tell the server that its a image via the headers but it could be something different ie a script... Any good developer will look out for this stuff though.
You can send custom HTTP headers from the browser with XMLHTTPRequest, commonly referred to as AJAX. Not totally sure if this is what the poster is referring to, but its possible.