NYCPHP Meetup

NYPHP.org

[nycphp-talk] Downloading File Outside of the Root

Randal Rust randalrust at gmail.com
Wed Dec 3 15:23:06 EST 2008


We are working on a small site where the client has an eBook for sale.
Once the purchase is completed, we want to provide the link to the
file, which we'd like to have sit outside of the server root. We are
trying to work this out by modifying the .htaccess file with the
following command.

RewriteRule
^download/pdf/book.pdf
/home/cooking/wwwroot/pdf/book.pdf

Unfortunately we keep getting 404 errors. This is a shared
environment, so the host may not even allow this, but does anyone see
anything that would keep this from working properly? FYI, I spaced it
out here for readability. It's one line in the file.

-- 
Randal Rust
R.Squared Communications
www.r2communications.com
614-370-0036



More information about the talk mailing list