I know my file exists but somehow the script is not finding it. The file I want my visitors to download is an .epub book, mimetype is 'epub+zip', set as ''epub' => 'application/epub+zip',". I'm working with Windows 7 and Firefox/Safari/Opera.
I used "echo $_SERVER["DOCUMENT_ROOT"];" to find that BASE_DIR on the server is '/content/Hosting/b/o/www.bosburyhistoryresource.org.uk/web/' and added it to the php script.
On my webpage the html link is <a href="http://www.bosburyhistoryresource.org.uk/epub/download.php?f=bentleyshortaccount.epub">
and bentleyshortaccount.epub and download.php are in the same directory, the html link page is in the root directory.
Somehow I think the $dirname, $fname and $file_path variables are not pulling out the correct data. I am going to try to use ECHO to see if I can look at what values these variables have been given but any other ideas would be useful.
Also is the "&" in "function find_file ($dirname, $fname, &$file_path) {" correct?
Regards
Barry Sharples