# Alchimistes : redirections de la refonte (à garder au-dessus de « # ~~start~~ »)
<IfModule mod_rewrite.c>
RewriteEngine on
# Pages « marques » retirées (logos clients sans accord) : chacune vers l'accueil
# /brand/1-studio-design
RewriteRule ^brand/1(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# /brand/2-graphic-corner
RewriteRule ^brand/2(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# /brand/3-orange
RewriteRule ^brand/3(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# /brand/4-sncf
RewriteRule ^brand/4(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# /brand/5-inseec
RewriteRule ^brand/5(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# /brand/6-mcdo
RewriteRule ^brand/6(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# /brand/7-université-bordeaux
RewriteRule ^brand/7(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# /brand/8-ford
RewriteRule ^brand/8(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# /brand/9-l-oral
RewriteRule ^brand/9(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# /brand/10-total
RewriteRule ^brand/10(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# /brand/11-canal
RewriteRule ^brand/11(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
RewriteRule ^brands/?$ https://%{HTTP_HOST}/ [R=301,L]
# Anciennes catégories en double ou vides : vers la famille du menu (n° de catégorie, sans les fiches produits en .html)
RewriteRule ^(13|18|19|20|326|327|328|329|401)(-[^/.]*)?/?$ https://%{HTTP_HOST}/336-sweat [R=301,L]
RewriteRule ^(14|255|256|400)(-[^/.]*)?/?$ https://%{HTTP_HOST}/332-t-shirts [R=301,L]
RewriteRule ^(15|399)(-[^/.]*)?/?$ https://%{HTTP_HOST}/333-polos [R=301,L]
RewriteRule ^(17|31|33|34|53|54|57|58|59|71|72|73|74|75|76|77|78|79|80|81|82|83|84|85|86|87|88|89|90|109|110|111|112|113|114|115|116|117|118|119|120|121|122|123|124|125|135|136|137|138|139|140|141|142|143|215|216|244|245|246|248|249|267|283|284|286|288|289|290)(-[^/.]*)?/?$ https://%{HTTP_HOST}/content/9-goodies [R=301,L]
RewriteRule ^(397|398|402|403|404|405|406|407)(-[^/.]*)?/?$ https://%{HTTP_HOST}/396-native-spirit [R=301,L]
RewriteRule ^(410|411)(-[^/.]*)?/?$ https://%{HTTP_HOST}/408-sacs-accessoires [R=301,L]
# Ancienne adresse de l'accueil (l'accueil est maintenant à « / »)
RewriteRule ^accueil/?$ https://%{HTTP_HOST}/ [R=301,L]
# Ancienne page « Demande de devis » : le devis se fait maintenant sur /nous-contacter
RewriteRule ^content/6(-[^/]*)?/?$ https://%{HTTP_HOST}/nous-contacter [R=301,L]
# Page « produits-made-in-france » retirée (décision du 6 octobre 2026) : vers le catalogue textile
RewriteRule ^content/10(-[^/]*)?/?$ https://%{HTTP_HOST}/330-nos-textiles [R=301,L]
# Page « paiement-securise » retirée (décision du 7 octobre 2026 : plus de paiement en ligne) : vers l'accueil
RewriteRule ^content/5(-[^/]*)?/?$ https://%{HTTP_HOST}/ [R=301,L]
# Page n° 11 « blaklader-personnalise-bordeaux », vide (décision du 7 octobre 2026) : vers la page Blåkläder n° 12
RewriteRule ^content/11(-[^/]*)?/?$ https://%{HTTP_HOST}/content/12-blaklader [R=301,L]
</IfModule>
# Cache des navigateurs (vitesse) : un mois pour les styles, scripts, images, vidéos et polices.
# Les styles et scripts du nouveau thème changent d'adresse à chaque mise à jour (?v=...), donc aucun risque de vieille version.
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType text/css "access plus 1 month"
ExpiresByType application/javascript "access plus 1 month"
ExpiresByType text/javascript "access plus 1 month"
ExpiresByType image/jpeg "access plus 1 month"
ExpiresByType image/png "access plus 1 month"
ExpiresByType image/gif "access plus 1 month"
ExpiresByType image/webp "access plus 1 month"
ExpiresByType image/svg+xml "access plus 1 month"
ExpiresByType video/mp4 "access plus 1 month"
ExpiresByType font/woff2 "access plus 1 month"
ExpiresByType font/woff "access plus 1 month"
</IfModule>
# ~~start~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again
# .htaccess automaticaly generated by PrestaShop e-commerce open-source solution
# http://www.prestashop.com - http://www.prestashop.com/forums

<IfModule mod_rewrite.c>
<IfModule mod_env.c>
SetEnv HTTP_MOD_REWRITE On
</IfModule>

RewriteEngine on


#Domain: alchimistes.fr
RewriteRule . - [E=REWRITEBASE:/]
RewriteRule ^api(?:/(.*))?$ %{ENV:REWRITEBASE}webservice/dispatcher.php?url=$1 [QSA,L]

# Images
RewriteCond %{HTTP_HOST} ^alchimistes.fr$
RewriteRule ^([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$1$2$3.jpg [L]
RewriteCond %{HTTP_HOST} ^alchimistes.fr$
RewriteRule ^([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$1$2$3$4.jpg [L]
RewriteCond %{HTTP_HOST} ^alchimistes.fr$
RewriteRule ^([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$1$2$3$4$5.jpg [L]
RewriteCond %{HTTP_HOST} ^alchimistes.fr$
RewriteRule ^([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$1$2$3$4$5$6.jpg [L]
RewriteCond %{HTTP_HOST} ^alchimistes.fr$
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$1$2$3$4$5$6$7.jpg [L]
RewriteCond %{HTTP_HOST} ^alchimistes.fr$
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$1$2$3$4$5$6$7$8.jpg [L]
RewriteCond %{HTTP_HOST} ^alchimistes.fr$
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$7/$1$2$3$4$5$6$7$8$9.jpg [L]
RewriteCond %{HTTP_HOST} ^alchimistes.fr$
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$7/$8/$1$2$3$4$5$6$7$8$9$10.jpg [L]
RewriteCond %{HTTP_HOST} ^alchimistes.fr$
RewriteRule ^c/([0-9]+)(\-[\.*_a-zA-Z0-9-]*)(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/c/$1$2$3.jpg [L]
RewriteCond %{HTTP_HOST} ^alchimistes.fr$
RewriteRule ^c/([a-zA-Z_-]+)(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/c/$1$2.jpg [L]
# AlphaImageLoader for IE and fancybox
RewriteRule ^images_ie/?([^/]+)\.(jpe?g|png|gif)$ js/jquery/plugins/fancybox/images/$1.$2 [L]

# Dispatcher
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ %{ENV:REWRITEBASE}index.php [NC,L]
</IfModule>

AddType application/vnd.ms-fontobject .eot
AddType font/ttf .ttf
AddType font/otf .otf
AddType application/font-woff .woff
AddType font/woff2 .woff2
<IfModule mod_headers.c>
	<FilesMatch "\.(ttf|ttc|otf|eot|woff|woff2|svg)$">
		Header set Access-Control-Allow-Origin "*"
	</FilesMatch>
</IfModule>

#If rewrite mod isn't enabled
ErrorDocument 404 /index.php?controller=404

# ~~end~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again