0

Using mod_rewrite I use this to test if a file exists:

RewriteCond /home/myact/public_html/pagecache%{REQUEST_URI}/index.html -f

How can I test if the file exists and is less than 5 minutes old?

2
Contributors
4
Replies
5
Views
7 Years
Discussion Span
Last Post by hknight
0

Using a script or from within Apache?

I would like to do this as a RewriteCond

0

I think you will need to use a CondPattern in that RewriteCond but not sure if it will work. The CondPattern takes on a perl syntax. So, if you can test it with a Perl test, you'll have it. Sorry, that I don't have more info on that. I've never heard of this type of need before.

0

I think you will need to use a CondPattern in that RewriteCond but not sure if it will work. The CondPattern takes on a perl syntax. So, if you can test it with a Perl test, you'll have it. Sorry, that I don't have more info on that. I've never heard of this type of need before.

Thanks, in that case I may as well rewrite everything to PHP and let PHP do the work.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.