Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
默认情况下,当我请求图像文件时 - 石匠处理程序会触发autohandler吗?只有.html文件被设置为由 mason 在配置文件中处理。我需要它来做一些后台任务,但我不希望图像文件本身被处理。请指教...
autohandler
.html
更新,我将尝试以下内容autohandler:
return -1 if $r->content_type && $r->content_type !~ m|^text/|i;
并带有以下内容apache2.conf:
apache2.conf
<FilesMatch "(.*)>
尝试使用 LocationMatch:
<LocationMatch "\.(css|html)$"> SetHandler perl-script PerlHandler ...# it depends on your current configuration </LocationMatch>
您还说您不想处理图像,将这些图像文件放在另一个目录中并让默认处理程序为其提供服务:
<Location /images> sethandler default-handler </Location>