hosting:cms:prestashop:htaccess

Различия

Здесь показаны различия между двумя версиями данной страницы.

Ссылка на это сравнение

Предыдущая версия справа и слева Предыдущая версия
Следующая версия
Предыдущая версия
hosting:cms:prestashop:htaccess [2019/07/31 16:34]
karlov
hosting:cms:prestashop:htaccess [2019/08/29 12:19] (текущий)
karlov
Строка 1: Строка 1:
-====== Стандартные .htaccess для PrestaShop ======+====== ​2.13.10.9. ​Стандартные .htaccess для PrestaShop ======
  
-Содержимое стандартных ''​.htaccess''​ для PrestaShop:​ +{{tag>​cms prestashop htaccess}} 
-  * Из [[hosting:​my-sites:​site-settings:​root-dir|корневого каталога]] сайта:<​code apache ​.htaccess ​[enable_line_numbers="​true"​]>​+ 
 +Пример содержимого стандартных ''​[[hosting:​htaccess|.htaccess]]''​ для PrestaShop ​(генерируется автоматически при установке)
 +  * Из [[hosting:​my-sites:​site-settings:​root-dir|корневого каталога]] сайта:<​code apache [enable_line_numbers="​true"​]>​
 # ~~start~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again # ~~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 # .htaccess automaticaly generated by PrestaShop e-commerce open-source solution
Строка 15: Строка 17:
  
  
-#​Domain: ​ps17.rndm.gq+#​Domain: ​www.example.com
 RewriteRule . - [E=REWRITEBASE:/​] RewriteRule . - [E=REWRITEBASE:/​]
 RewriteRule ^api(?:/​(.*))?​$ %{ENV:​REWRITEBASE}webservice/​dispatcher.php?​url=$1 [QSA,L] RewriteRule ^api(?:/​(.*))?​$ %{ENV:​REWRITEBASE}webservice/​dispatcher.php?​url=$1 [QSA,L]
  
 # Images # Images
-RewriteCond %{HTTP_HOST} ^ps17.rndm.gq$+RewriteCond %{HTTP_HOST} ^www.example.com$
 RewriteRule ^([0-9])(\-[_a-zA-Z0-9-]*)?​(-[0-9]+)?/​.+\.jpg$ %{ENV:​REWRITEBASE}img/​p/​$1/​$1$2$3.jpg [L] RewriteRule ^([0-9])(\-[_a-zA-Z0-9-]*)?​(-[0-9]+)?/​.+\.jpg$ %{ENV:​REWRITEBASE}img/​p/​$1/​$1$2$3.jpg [L]
-RewriteCond %{HTTP_HOST} ^ps17.rndm.gq$+RewriteCond %{HTTP_HOST} ^www.example.com$
 RewriteRule ^([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?​(-[0-9]+)?/​.+\.jpg$ %{ENV:​REWRITEBASE}img/​p/​$1/​$2/​$1$2$3$4.jpg [L] 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} ^ps17.rndm.gq$+RewriteCond %{HTTP_HOST} ^www.example.com$
 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] 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} ^ps17.rndm.gq$+RewriteCond %{HTTP_HOST} ^www.example.com$
 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] 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} ^ps17.rndm.gq$+RewriteCond %{HTTP_HOST} ^www.example.com$
 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] 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} ^ps17.rndm.gq$+RewriteCond %{HTTP_HOST} ^www.example.com$
 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] 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} ^ps17.rndm.gq$+RewriteCond %{HTTP_HOST} ^www.example.com$
 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] 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} ^ps17.rndm.gq$+RewriteCond %{HTTP_HOST} ^www.example.com$
 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] 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} ^ps17.rndm.gq$+RewriteCond %{HTTP_HOST} ^www.example.com$
 RewriteRule ^c/​([0-9]+)(\-[\.*_a-zA-Z0-9-]*)(-[0-9]+)?/​.+\.jpg$ %{ENV:​REWRITEBASE}img/​c/​$1$2$3.jpg [L] RewriteRule ^c/​([0-9]+)(\-[\.*_a-zA-Z0-9-]*)(-[0-9]+)?/​.+\.jpg$ %{ENV:​REWRITEBASE}img/​c/​$1$2$3.jpg [L]
-RewriteCond %{HTTP_HOST} ^ps17.rndm.gq$+RewriteCond %{HTTP_HOST} ^www.example.com$
 RewriteRule ^c/​([a-zA-Z_-]+)(-[0-9]+)?/​.+\.jpg$ %{ENV:​REWRITEBASE}img/​c/​$1$2.jpg [L] RewriteRule ^c/​([a-zA-Z_-]+)(-[0-9]+)?/​.+\.jpg$ %{ENV:​REWRITEBASE}img/​c/​$1$2.jpg [L]
 # AlphaImageLoader for IE and fancybox # AlphaImageLoader for IE and fancybox
Строка 67: Строка 69:
 # ~~end~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again # ~~end~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again
 </​code>​ </​code>​
-  * Из подкаталога [[hosting:​cms:​prestashop:​admin|админ-панели]] ([[https://​github.com/​PrestaShop/​PrestaShop/​blob/​develop/​admin-dev/​.htaccess|GitHub]]):<​code apache ​.htaccess ​[enable_line_numbers="​true",​highlight_lines_extra="​17"​]>​+  * Из подкаталога [[hosting:​cms:​prestashop:​admin|админ-панели]] ([[https://​github.com/​PrestaShop/​PrestaShop/​blob/​develop/​admin-dev/​.htaccess|GitHub]]):<​code apache [enable_line_numbers="​true",​highlight_lines_extra="​17"​]>​
 # Use the front controller as index file. It serves as a fallback solution when # Use the front controller as index file. It serves as a fallback solution when
 # every other rewrite/​redirect fails (e.g. in an aliased environment without # every other rewrite/​redirect fails (e.g. in an aliased environment without
Строка 145: Строка 147:
     </​IfModule>​     </​IfModule>​
 </​IfModule>​ </​IfModule>​
-</​code>​ +</​code>​Директива в строке 17 закомментирована для [[hosting:​htaccess:​unsupported-options|совместимости]] с нашим хостингом.
- +
-Директива в строке 17 закомментирована для [[hosting:​htaccess:​unsupported-options|совместимости]] с нашим хостингом.+
  
 ===== Другие статьи ===== ===== Другие статьи =====
  
 {{indexmenu>​.#​1|nsort tsort}} {{indexmenu>​.#​1|nsort tsort}}
  • hosting/cms/prestashop/htaccess.1564580073.txt.gz
  • Последние изменения: 2019/07/31 16:34
  • — karlov