Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

Coding Forum


You are currently viewing our Coding Forum as a guest. Please register to participate.
Login



Reply
htaccess rewrite problem
Old 10-24-2004, 10:36 AM htaccess rewrite problem
questionmark's Avatar
Junior Talker

Posts: 2
Trades: 0
I use a .htaccess file on my site that looks like:
Code:
RewriteEngine On
RewriteCond %{HTTP_REFERER} !^http://www.mijn-domein.nl/download.php.* [NC]
RewriteRule /* http://www.mijn-domiein.nl/errordocs/403.html [R,L]
This .htaccess file protects some mainly word files in some directory. In the download.php file are links to these word files. The protection works great but when you right click on the link and choose "save target as..." you are also redirected to the 403.html file.

Is it possible to let users direct;y save these files, by right clicking or in any other way downloading it (not opening the file)?
questionmark is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 10-24-2004, 08:47 PM
vivekar's Avatar
Webmaster Talker

Posts: 612
Trades: 0
No way.

When you do not allow your users to view the doc files, how can you make them download it.

You have to move your doc files to a downloadable section.
Or, you have to restrict access via some password protection and then allow the download.
__________________

Please login or register to view this content. Registration is FREE
(Active since 2003) |
Please login or register to view this content. Registration is FREE
vivekar is offline
Reply With Quote
View Public Profile Visit vivekar's homepage!
 
Old 10-25-2004, 03:55 AM
questionmark's Avatar
Junior Talker

Posts: 2
Trades: 0
They do have to log in (mySQL log-in system) to view the download.php file. That's why they have to come from that file (see htaccess code in earlier post). In the download.php file are links to these files.

So logged-in visitors are able to VIEW them.
But I want them to be able to download it when they right click the link.
questionmark is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to htaccess rewrite problem
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.12325 seconds with 12 queries