Hi,

I have a problem with checking if a file exists. Due to server restrictions, I cant do this in PHP so I am hoping there is a way to do it in javascript.

I have a page that passes $day, $date and $year through a form.

These are then used in a url like this track$day$month$year.html ie: track12022003.html

What I need is the code to check if the file exists, if it does it will go that file and if it doesnt it will go to noresults.html

ie:
PHP Code:
file track$day$month$year.html
if(file exists){
 
go to the file's url
else{
 the file doesnt exist so load the noresults.html fil;e

Any help with this is appreciated.

Thanks,
Martin