I'm having trouble redirecting urls that include cgi-bin in the path
Example:
http://website.com/cgi-bin/pc.storefront/en/product/product.aspx?iid=123
.htaccess
redirect 301 /cgi-bin/pc.storefront/en/product/product.aspx?iid=123 http://website.com/homepage.html
With that redirect the server returns: /cgi-bin/pc.storefront/en/product/product.aspx does not exist on this server error messaging.
However, if keeping everything the same and removing cgi-bin from the equation then the redirect works perfectly.
The server is apache2 using mod_rewrite. cgi is also disabled in httpd.conf. Are the any concerns related to redirecting cgi-bin?
There is usually a default set of directives that come "out of the box" for more Apache configurations. This default often includes a
AllowOverride none
directive on thecgi-bin
folder/alias.AllowOverride none
means .htaccess files in the folder/alias will be ignored.Try updating the main config directive to
AllowOverride Fileinfo