Re: checking for a file
- From: Jonathan N. Little <lws4art@xxxxxxxxxxxxx>
- Date: Fri, 19 May 2006 18:36:53 -0400
In article <p-adneUqib3MYPDZRVn-tw@xxxxxxxxxxx>, nospam@xxxxxxxxx says...
Andy Dingley wrote:
Is it possible to check for existence of a file from a web page using
No, it's impossible. It's forbidden by the sheer impossibiility of
accessing the server's filesystem from a remote web client, and by the
sandboxing that would obviously applied if such a feature were even
As to the client, then you're again sandboxed from looking around the
client's filesystem (and for good reason). There's a tiny amount that's
possible through manual file upload on a form, but that's hardly
I'm not trying to do a directory listng, I'm loading a series of images
(with specific filenames) in a loop, and if one is missing i want to break
out of the loop. So is that possible?
After and image loads it trips a onload event. I guess you *could* timed
loop (would require much tweaking to get it right) to test if the onload
could never know definitively that an image is missing, only that it did
not full load by some specific time that you preset. It coul be that the
image is larger, visitor's connection is slow...whatever. My opinion very
Much better idea: put all image in a specified folder, say "slideshow"
then with PHP get a listing of the contents of the "slideshow" folder and
slideshow! Then all you have to do is whatever you want in the show put
it in the folder, the rest is all automatic...
- Prev by Date: Re: quastion about frames
- Next by Date: Re: psds, dreamweaver, image maps
- Previous by thread: Re: checking for a file
- Next by thread: Re: checking for a file