Integrating a .htaccess into a httpd.conf -
i'vee got following htaccess file in /connect folder , need integrate httpd.conf file (which has commands already):
/connect/.htaccess
setenv application_env development rewriteengine on rewritebase /connect rewritecond %{request_filename} -s [or] rewritecond %{request_filename} -l [or] rewritecond %{request_filename} -d rewriterule ^.*$ - [nc,l] rewriterule ^.*$ index.php [nc,l] httpd.conf
... namevirtualhost *:80 <virtualhost *:80> documentroot /var/www/html/alter servername www.mysite.com <ifmodule mod_rewrite.c> rewriteengine on rewritecond %{http_host} !^www\. rewritecond %{https}s ^on(s)| rewriterule ^ http%1://www.%{http_host}%{request_uri} [l,r=301] ... .... i'm not sure how can fit above below?
a .htaccess guts of block in httpd.conf, you'd want like
<virtualhost *:80> documentroot ... servername ... etc.... <directory /var/www/html/alter> ... guts of .htaccess here ... </directory> </virtualhost> though, should make such chance once you're satisified .htaccess working , not changed (much) anymore. changes httpd.conf require bounce server, while .htaccess changes take effect next request.
Comments
Post a Comment