First off, does search here suck all the time or only on occasion now? I always try and search for something related to a query before I post one, but generally all I get is the "wait" GIF, and, after 30 seconds or so, I assume there's nothing here related to my issue, close the browser tab and reopen another one to post a question.

I've been using file_get_contents() to download images we use from our sellers. One of them is using IIS 7.0 and is sending Content-Disposition:attachment and it's causing some issues. Is it possible to ignore this header?

    Thanks for the reply. I've already decided to do some testing with cURL, so it's nice to have someone else confirm that I'm not crazy. 😃

    dalecosp I can't comment on what might happen with file_get_contents when you get a content-disposition header as I have not replicated the situation. I will say that I almost never use file_get_contents or other such functions for fetching remote files because it's subject to the PHP config and remote urls are typically disabled by default. CURL is not always installed, but I find that in practice it usually is. You get a lot more control. In fact, there are so many options that I pretty much always write a class or custom function to encapsulate my curl code.

    Write a Reply...