Conditional error documents uri in .htaccess

wanah

Well-Known Member
#1
Hello,
We're looking for the equivalent way to do the following Apache 2.4 statement in LiteSpeed :
Code:
<If "-f %{DOCUMENT_ROOT} . '/.custom404.txt'">
ErrorDocument 404 /mycustom404.html
</If>
The if statement doesn't seem to be recognised in LiteSpeed 5.1, is there another way to say if a file exists then change the Error Document URI ?
 

mistwang

LiteSpeed Staff
#2
No, we cannot do that, and it may not work that well as we cache the .htaccess, so <If > wont be evaluated for each every request, like Apache did, it re-parse the .htaccess for each request.
 
Top