N
Neil Charlton
HI
I would like to test for the existence of a file over HTTP. I have tried
various combinations of File.stat and FileTest.exists? with no results.
For example (image.jpg exists)
if FileTest.exists?("http://domain.com/image.jpg")
puts "found file"
end
does not print found file even though the file exists
What am I doing wrong ?
Thanks in Advance
I would like to test for the existence of a file over HTTP. I have tried
various combinations of File.stat and FileTest.exists? with no results.
For example (image.jpg exists)
if FileTest.exists?("http://domain.com/image.jpg")
puts "found file"
end
does not print found file even though the file exists
What am I doing wrong ?
Thanks in Advance