R
R
rabodis2020-10-03 19:54:20
htaccess
rabodis, 2020-10-03 19:54:20

How to make a stub on a site with access to a file?

When entering the site, the user is shown a stub - maintenance.php


RewriteCond %{REQUEST_URI} !/maintenance.php $ RewriteRule $ /maintenance.php
[R=302,L]


it, the user gets back to maintenance.php

. Additional access to the /documents/file.pdf file is needed to download the file.

How to set up htaccess?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Viktor Taran, 2020-10-04
@rabodis

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-l
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !/maintenance.php $
RewriteRule $ /maintenance.php [R=302,L]

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question