Forum Moderators: phranque
Options -MultiViews
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
#RewriteRule ^(.*)$ $1.php [L,QSA]
RewriteRule ^search([\/]?)$ index.php?option=collection-products§ion=collection&%{QUERY_STRING} [L,QSA]
RewriteRule ^page\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=pages&url=$1&%{QUERY_STRING} [L,QSA]
RewriteRule ^product\/([a-zA-Z0-9_-]+)\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=product&category=$1&producturl=$2&%{QUERY_STRING} [L,QSA]
RewriteRule ^products\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=collection-products§ion=collection&productcat=$1&%{QUERY_STRING} [L,QSA]
RewriteRule ^products\/([a-zA-Z0-9_-]+)\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=collection-products§ion=collection&category=$1&productcat=$2&%{QUERY_STRING} [L,QSA]
RewriteRule ^products\/([a-zA-Z0-9_-]+)\/([a-zA-Z0-9_-]+)\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=collection-products&category=$1§ion=collection&subcategory=$2&productcat=$3&%{QUERY_STRING} [L,QSA]
RewriteRule ^collection\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=collection§ion=collection&category=$1&%{QUERY_STRING} [L,QSA]
RewriteRule ^collection\/([a-zA-Z0-9_-]+)\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=collection§ion=collection&category=$1&subcategory=$2&%{QUERY_STRING} [L,QSA]
#RewriteRule ^detail\/([a-zA-Z0-9_-]+)\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=cat_page_more§ion=$1&category=$2&%{QUERY_STRING} [L,QSA]
#RewriteRule ^philanthropy([\/]?)$ index.php?option=our-work§ion=philanthropy&&%{QUERY_STRING} [L,QSA]
RewriteRule ^philanthropy\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=cat_pages§ion=philanthropy&category=$1&%{QUERY_STRING} [L,QSA]
RewriteRule ^philanthropy\/([a-zA-Z0-9_-]+)\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=cat_page_detail§ion=philanthropy&category=$1&pageurl=$2&%{QUERY_STRING} [L,QSA]
RewriteRule ^our-work\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=cat_pages§ion=our-work&category=$1&%{QUERY_STRING} [L,QSA]
RewriteRule ^our-work\/([a-zA-Z0-9_-]+)\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=cat_page_detail§ion=our-work&category=$1&pageurl=$2&%{QUERY_STRING} [L,QSA]
RewriteRule ^([a-zA-Z0-9_-]+)\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=cat_page_detail§ion=$1&pageurl=$2&%{QUERY_STRING} [L,QSA]
RewriteRule ^our-services([\/]?)$ index.php?option=cat_pages§ion=our-services&%{QUERY_STRING} [L,QSA]
#RewriteRule ^philanthropy([\/]?)$ index.php?option=cat_pages§ion=philanthropy&%{QUERY_STRING} [L,QSA]
RewriteRule ^conceptual-gift-design([\/]?)$ index.php?option=cat_pages§ion=conceptual-gift-design&%{QUERY_STRING} [L,QSA]
#RewriteRule ^our-services\/([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=cat_page_detail§ion=our-services&pageurl=$1&%{QUERY_STRING} [L,QSA]
#RewriteRule ^our-work([\/]?)$ index.php?option=collection§ion=our-work&%{QUERY_STRING} [L,QSA]
RewriteRule ^([a-zA-Z0-9_-]+)([\/]?)$ index.php?option=$1&%{QUERY_STRING} [L,QSA] 1. What is this code trying to accomplish?
2. And what role, if any, do symlinks have to play in this (meaning, how do I get the URL's to properly direct to the .php files using it)?
RewriteRule ^search/?$ index.php?option=collection-products§ion=collection&%{QUERY_STRING} [L,QSA]
The absence of an extension in the URL made me think there was an .htaccess file, and there was
RewriteRule ^search/?$ as a pattern promotes duplicate content because URLs both with or without a trailing slash return the same content.