# invoke rewrite engine
RewriteEngine On
RewriteBase /

Options -Indexes
<IfModule mod_negotiation.c>
	Options -MultiViews
</IfModule>

# Redirect non-www to www
RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]

# Specific redirections
RewriteRule ^index\.html$ / [L,R=301]
RewriteCond %{QUERY_STRING} ^option=com_specials&view=specials&layout=print&special_id=3&tmpl=component&templateStyle=11$
RewriteRule ^index\.php$ index_option-com_specials-view-specials-layout-print-special_id-3-tmpl-component-templateStyle-11 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^mode=quote$
RewriteRule ^contact-us$ contact-us_mode-quote [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^mode=question$
RewriteRule ^contact-us$ contact-us_mode-question [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=3$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-3 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=6$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-6 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=9$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-9 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=12$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-12 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=15$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-15 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=18$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-18 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=21$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-21 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=24$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-24 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=27$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-27 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^$ pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=235&id=18&layout=blog&view=category&limitstart=3$
RewriteRule ^index\.php$ index_option-com_content-Itemid-235-id-18-layout-blog-view-category-limitstart-3 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=235&id=18&layout=blog&view=category&limitstart=6$
RewriteRule ^index\.php$ index_option-com_content-Itemid-235-id-18-layout-blog-view-category-limitstart-6 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=235&id=18&layout=blog&view=category&limitstart=9$
RewriteRule ^index\.php$ index_option-com_content-Itemid-235-id-18-layout-blog-view-category-limitstart-9 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=69$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-69 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_vehicleowner&view=registration&Itemid=148$
RewriteRule ^index\.php$ index_option-com_vehicleowner-view-registration-Itemid-148 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_vehicleowner&view=profile&Itemid=224$
RewriteRule ^index\.php$ index_option-com_vehicleowner-view-profile-Itemid-224 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=66$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-66 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=60$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-60 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_mailto&tmpl=component&template=gantry&link=9610fef1c03a34a1fad455f8c8a158e7ee0050fc$
RewriteRule ^index\.php$ index_option-com_mailto-tmpl-component-template-gantry-link-9610fef1c03a34a1fad455f8c8a158e7ee0050fc [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_mailto&tmpl=component&template=gantry&link=88506519e5fe4ed1d96940711be5b2c5353ba246$
RewriteRule ^index\.php$ index_option-com_mailto-tmpl-component-template-gantry-link-88506519e5fe4ed1d96940711be5b2c5353ba246 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/how-can-you-tell-if-your-car-battery-needs-replacing$ blog/how-can-you-tell-if-your-car-battery-needs-replacing/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/how-do-you-know-when-your-muffler-is-bad$ blog/how-do-you-know-when-your-muffler-is-bad/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/how-often-do-you-need-brakes-replaced$ blog/how-often-do-you-need-brakes-replaced/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/how-often-do-you-need-to-change-your-tires$ blog/how-often-do-you-need-to-change-your-tires/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/how-often-should-you-get-a-tune-up-on-your-car$ blog/how-often-should-you-get-a-tune-up-on-your-car/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/how-often-should-you-get-maintenance-on-your-car$ blog/how-often-should-you-get-maintenance-on-your-car/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/looking-for-quality-automotive-service$ blog/looking-for-quality-automotive-service/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/what-are-the-benefits-of-regular-car-servicing$ blog/what-are-the-benefits-of-regular-car-servicing/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/what-are-the-signs-of-engine-problems$ blog/what-are-the-signs-of-engine-problems/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/what-can-your-auto-shop-do-for-you$ blog/what-can-your-auto-shop-do-for-you/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog/what-happens-if-you-dont-replace-struts$ blog/what-happens-if-you-dont-replace-struts/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f$
RewriteRule ^blog$ blog/pt-f [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^index\.php$ index_php [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f&option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=12$
RewriteRule ^index\.php$ index_pt-f-option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-12 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f&option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=15$
RewriteRule ^index\.php$ index_pt-f-option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-15 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=174$
RewriteRule ^index\.php$ index_option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-174 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f&option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=18$
RewriteRule ^index\.php$ index_pt-f-option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-18 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f&option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=21$
RewriteRule ^index\.php$ index_pt-f-option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-21 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f&option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=24$
RewriteRule ^index\.php$ index_pt-f-option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-24 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f&option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=27$
RewriteRule ^index\.php$ index_pt-f-option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-27 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f&option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=3$
RewriteRule ^index\.php$ index_pt-f-option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-3 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f&option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=6$
RewriteRule ^index\.php$ index_pt-f-option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-6 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f&option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=66$
RewriteRule ^index\.php$ index_pt-f-option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-66 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^pt=f&option=com_content&Itemid=234&id=17&layout=blog&view=category&limitstart=9$
RewriteRule ^index\.php$ index_pt-f-option-com_content-Itemid-234-id-17-layout-blog-view-category-limitstart-9 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_specials&view=specials&layout=print&special_id=1&tmpl=component&templateStyle=11$
RewriteRule ^index\.php$ index_option-com_specials-view-specials-layout-print-special_id-1-tmpl-component-templateStyle-11 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_specials&view=specials&layout=print&special_id=2&tmpl=component&templateStyle=11$
RewriteRule ^index\.php$ index_option-com_specials-view-specials-layout-print-special_id-2-tmpl-component-templateStyle-11 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^layout=print&option=com_specials&special_id=3&templateStyle=11&tmpl=component&view=specials$
RewriteRule ^index\.php$ index_layout-print-option-com_specials-special_id-3-templateStyle-11-tmpl-component-view-specials [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_mailto&tmpl=component&template=gantry&link=1e6e49c8e28a723e5db2a00add4caac41976b8c4$
RewriteRule ^index\.php$ index_option-com_mailto-tmpl-component-template-gantry-link-1e6e49c8e28a723e5db2a00add4caac41976b8c4 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_mailto&tmpl=component&template=gantry&link=95503501dc099b471e49c9ad9909596900751022$
RewriteRule ^index\.php$ index_option-com_mailto-tmpl-component-template-gantry-link-95503501dc099b471e49c9ad9909596900751022 [L,R=301,QSD]
RewriteCond %{QUERY_STRING} ^option=com_vehicleowner&task=login\._is_login&tmpl=component$
RewriteRule ^index\.php$ index_option-com_vehicleowner-task-login_is_login-tmpl-component [L,R=301,QSD]

# Create pretty URLs
DirectorySlash Off

RewriteCond %{THE_REQUEST} /([^.]+)\.html [NC]
RewriteRule ^ %1 [NC,L,R=301]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_URI} (.*)/$
RewriteRule ^(.*)/$ $1 [NC,L,R=301]

RewriteCond %{REQUEST_FILENAME}.html -f
RewriteRule ^ %{REQUEST_URI}.html [NC,L]
# End: Create pretty URLs

# Redirect all extensions to html
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^(.*)\.shtml$ $1.html [L,NC,R=301]
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^(.*)\.phtml$ $1.html [L,NC,R=301]
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^(.*)\.jhtml$ $1.html [L,NC,R=301]
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^(.*)\.htm$ $1.html [L,NC,R=301]
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^(.*)\.php$ $1.html [L,NC,R=301]
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^(.*)\.aspx$ $1.html [L,NC,R=301]
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^(.*)\.asp$ $1.html [L,NC,R=301]
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^(.*)\.jsp$ $1.html [L,NC,R=301]
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^(.*)\.apk$ $1.html [L,NC,R=301]
# End: Redirect all extensions to html
