I don't know if "hotlinking simulation" is actually what I need: I want to download images from this address (*): http://www.sat24.com/image.ashx?sat=vis&type=history&country=it&time=201002050900&sessionid=lu5gewaraqfnw0igmbcb5tuh Such addresses actually show images if hotlinked, but calling them by using Curl results in an error page. Can Curl behave in such a way linked server "thinks" it's an hotlinking? Or, how else can I get those images and save them on my server? (I'd like to build an animated gif, or at least a TAR archive). (*)This link will not work for you until you replace sessionid with a new one, which you can obtain by accessing the page in a standard manner: http://www.sat24.com/history.aspx?country=it Drag the image to the address bar to show its address with proper sessionid.
OK what you need to do is use a different image url. try this code. hope it will help you. <?php function getPage($url) { $ch = curl_init(); curl_setopt ($ch, CURLOPT_URL, $url); curl_setopt ($ch, CURLOPT_HEADER, 0); curl_setopt ($ch, CURLOPT_RETURNTRANSFER, true); $result = curl_exec ($ch); curl_close ($ch); return $result; } header ("Content-type: image/gif"); echo getPage('http://www.sat24.com/image.ashx?country=it&type=last&time=201002050700&sat='); ?> Code (markup):
this does not work, even by hand; I need to be able to choose date/hour and to download for VISIBILE rather than INFRARED channel.
This DOES work. For visible channel use this link http://www.sat24.com/image.ashx?country=it&type=slide&time=201002050800&index=1&sat=vis Code (markup): In the url you can see time=201002050800 this means it loads the image from 05.02.2010 8am change the time and date if you want to save the image then you need to use fopen, fwrite and fclose. But I can assure you that this DOES work I have TESTED it myself.
it works only for today Working: http://www.sat24.com/image.ashx?country=it&type=slide&time=201002050900&index=1&sat=vis Not working http://www.sat24.com/image.ashx?country=it&type=slide&time=201002020900&index=1&sat=vis But where do you get possible values for parameters?
found other interesting URLs to decode: http://www2.sat24.com/homepage.aspx?html=zoom&xas=360&yas=340 (note the www2) http://www2.sat24.com/mysat/1480-1460-METE_RGB-12-12-1_europa1500m-ano_1002051030.gif http://www.sat24.com/maptravelertijd.js http://www2.sat24.com/HomepageAnim.aspx?country=it&sat=vis&type=slide (click & zoom & pan) http://www2.sat24.com/image.ashx?country=eu&type=slide&index=1&sat