Re: file_exists on different server...

From: Date: Tue, 30 Sep 2003 11:26:22 +0000
Subject: Re: file_exists on different server...
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-164378@lists.php.net to get a copy of this message
On Tuesday 30 September 2003 19:00, Tristan.Pretty@risk.sungard.com wrote: > I'm referencing an image on a different server, and it keeps changing > URL's > Very odd, but t get round that, I tried... > > if > (file_exists("http://www.othersite.com/image_1.gif")) { > > $image_show="http://www.othersite.com/image_1.gif"; > } else { > > $image_show="http://www.mysite.com/image_1.gif"; > } > > but it always seems to do the else command, even though I know the file > DOES exist... RTFM Try fopen() or similar instead. -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * ------------------------------------------ Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general ------------------------------------------ /* If you are over 80 years old and accompanied by your parents, we will cash your check. */

« previous php.general (#164378) next »