Pelmen Опубликовано: января 9, 2017 Жалоба Поделиться Опубликовано: января 9, 2017 Приветствую! Занимаюсь интеграцией opencart.pro столкнулся с проблемой, магазин не отличает ссылки index.php?route=feed/rest_api/categories&level=2 И index.php?route=feed/rest_api/categories Как прописать в htacess или SeoPro, чтобы они оставались неизменными? Скрытый текст # 1.To use URL Alias you need to be running apache with mod_rewrite enabled. # 2. In your opencart directory rename htaccess.txt to .htaccess. # For any support issues please visit: http://www.opencart.com Options +FollowSymlinks # Prevent Directoy listing Options -Indexes # Prevent Direct Access to files <FilesMatch "(?i)((\.tpl|\.ini|\.log|(?<!robots)\.txt))"> Order deny,allow Deny from all </FilesMatch> # SEO URL Settings RewriteEngine On <IfModule mod_rewrite.c> RewriteCond %{QUERY_STRING} (eval\() [NC,OR] RewriteCond %{QUERY_STRING} (javascript:)(.*)(;) [NC,OR] RewriteCond %{QUERY_STRING} (base64_encode)(.*)(\() [NC,OR] RewriteCond %{QUERY_STRING} (GLOBALS|REQUEST)(=|\[|%) [NC,OR] RewriteCond %{QUERY_STRING} (<|%3C)(.*)script(.*)(>|%3) [NC,OR] RewriteCond %{QUERY_STRING} (\\|\.\.\.|\.\./|~|`|<|>|\|) [NC,OR] RewriteCond %{QUERY_STRING} (boot\.ini|etc/passwd|self/environ) [NC,OR] RewriteCond %{QUERY_STRING} (\'|\")(.*)(drop|insert|md5|select|union) [NC] RewriteRule .* - [F] </IfModule> # If your opencart installation does not run on the main web folder make sure you folder it does run in ie. / becomes /shop/ RewriteBase / RewriteRule ^sitemap.xml$ index.php?route=feed/google_sitemap [L] RewriteRule ^googlebase.xml$ index.php?route=feed/google_base [L] RewriteRule ^system/download/(.*) index.php?route=error/not_found [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_URI} !.*\.(ico|gif|jpg|jpeg|png|js|css) RewriteRule ^([^?]*) index.php?_route_=$1 [L,QSA] ####################################### OPENCART RESTFUL API START ################################################# #REST API database tables checksum RewriteRule ^api/rest/checksums index.php?route=feed/rest_api/getchecksum [L] ############################################ IMAGES ################################################################ #REST API add image to product RewriteRule ^api/rest/products/?([0-9]+)/images/other index.php?route=feed/rest_api/productimages&id=$1&other=1 [L] #REST API update product image RewriteRule ^api/rest/products/?([0-9]+)/images index.php?route=feed/rest_api/productimages&id=$1 [L] #REST API add image to category RewriteRule ^api/rest/categories/?([0-9]+)/images index.php?route=feed/rest_api/categoryimages&id=$1 [L] #REST API add image to manufacturer RewriteRule ^api/rest/manufacturers/?([0-9]+)/images index.php?route=feed/rest_api/manufacturerimages&id=$1 [L] #######################################PRODUCT###################################################################### #REST API selected product RewriteRule ^api/rest/products/?([0-9]+) index.php?route=feed/rest_api/products&id=$1 [L] #REST API products per category RewriteRule ^api/rest/products/category/?([0-9]+) index.php?route=feed/rest_api/products&category=$1 [L] #REST API products RewriteRule ^api/rest/products/ index.php?route=feed/rest_api/products [L] #REST API add products RewriteRule ^api/rest/products index.php?route=feed/rest_api/products [L] #REST API update products RewriteRule ^api/rest/products/?([0-9]+) index.php?route=feed/rest_api/products&id=$1 [L] #REST API delete products RewriteRule ^api/rest/products/?([0-9]+) index.php?route=feed/rest_api/products&id=$1 [L] #######################################CATEGORY#################################################################### #REST API categories filter parent and level RewriteRule ^api/rest/categories/parent/?([0-9]+)/level/?([0-9]+) index.php?route=feed/rest_api/categories&parent=$1&level=$2 [L] #REST API categories filter level RewriteRule ^api/rest/categories/level/?([0-9]+) index.php?route=feed/rest_api/categories&level=$1 [L] #REST API categories filter parent RewriteRule ^api/rest/categories/parent/?([0-9]+) index.php?route=feed/rest_api/categories&parent=$1 [L] #REST API selected category RewriteRule ^api/rest/categories/?([0-9]+) index.php?route=feed/rest_api/categories&id=$1 [L] #REST API categories RewriteRule ^api/rest/categories index.php?route=feed/rest_api/categories [L] #REST API add category RewriteRule ^api/rest/categories index.php?route=feed/rest_api/categories [L] #REST API update category RewriteRule ^api/rest/categories/?([0-9]+) index.php?route=feed/rest_api/categories&id=$1 [L] #REST API delete category RewriteRule ^api/rest/categories/delete/?([0-9]+) index.php?route=feed/rest_api/categories&id=$1 [L] #######################################MANUFACTURER################################################################# #REST API selected manufacturer RewriteRule ^api/rest/manufacturers/?([0-9]+) index.php?route=feed/rest_api/manufacturers&id=$1 [L] #REST API manufacturers RewriteRule ^api/rest/manufacturers index.php?route=feed/rest_api/manufacturers [L] #REST API add manufacturer RewriteRule ^api/rest/manufacturers index.php?route=feed/rest_api/manufacturers [L] #REST API update manufacturer RewriteRule ^api/rest/manufacturers/?([0-9]+) index.php?route=feed/rest_api/manufacturers&id=$1 [L] #REST API delete manufacturer RewriteRule ^api/rest/manufacturers/?([0-9]+) index.php?route=feed/rest_api/manufacturers&id=$1 [L] #######################################ORDERS###################################################################### #REST API selected orders RewriteRule ^api/rest/orders/?([0-9]+) index.php?route=feed/rest_api/orders&id=$1 [L] #REST API Orders with details RewriteRule ^api/rest/orders/details index.php?route=feed/rest_api/listorderswithdetails [L] #REST API update orders RewriteRule ^api/rest/orders/?([0-9]+) index.php?route=feed/rest_api/orders&id=$1 [L] #REST API delete orders RewriteRule ^api/rest/orders/?([0-9]+) index.php?route=feed/rest_api/orders&id=$1 [L] #REST API Orders filtered by user RewriteRule ^api/rest/orders/user/?([0-9]+) index.php?route=feed/rest_api/userorders&user=$1 [L] #REST API orders RewriteRule ^api/rest/orders index.php?route=feed/rest_api/orders [L] #######################################CUSTOMERS################################################################## #REST API selected customers RewriteRule ^api/rest/customers/?([0-9]+) index.php?route=feed/rest_api/customers&id=$1 [L] #REST API customers RewriteRule ^api/rest/customers index.php?route=feed/rest_api/customers [L] #REST API update customers RewriteRule ^api/rest/customers/update/?([0-9]+) index.php?route=feed/rest_api/customers&id=$1 [L] #REST API delete customers RewriteRule ^api/rest/customers/?([0-9]+) index.php?route=feed/rest_api/customers&id=$1 [L] #######################################LANGUAGES################################################################# #REST API selected language RewriteRule ^api/rest/languages/?([0-9]+) index.php?route=feed/rest_api/languages&id=$1 [L] #REST API languages RewriteRule ^api/rest/languages index.php?route=feed/rest_api/languages [L] ##############################################STORE############################################################### #REST API selected store RewriteRule ^api/rest/stores/?([0-9]+) index.php?route=feed/rest_api/stores&id=$1 [L] #REST API stores RewriteRule ^api/rest/stores index.php?route=feed/rest_api/stores [L] #######################################COUNTRY################################################################### #REST API selected country RewriteRule ^api/rest/countries/?([0-9]+) index.php?route=feed/rest_api/countries&id=$1 [L] #REST API countries RewriteRule ^api/rest/countries index.php?route=feed/rest_api/countries [L] #######################################SESSION##################################################################### #REST API get session RewriteRule ^api/rest/session index.php?route=feed/rest_api/session [L] #######################################OPENCART RESTFUL API END##################################################### ### Additional Settings that may need to be enabled for some servers ### Uncomment the commands by removing the # sign in front of it. ### If you get an "Internal Server Error 500" after enabling any of the following settings, restore the # as this means your host doesn't allow that. # 1. If your cart only allows you to add one item at a time, it is possible register_globals is on. This may work to disable it: # php_flag register_globals off # 2. If your cart has magic quotes enabled, This may work to disable it: # php_flag magic_quotes_gpc Off # 3. Set max upload file size. Most hosts will limit this and not allow it to be overridden but you can try # php_value upload_max_filesize 999M # 4. set max post size. uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields # php_value post_max_size 999M # 5. set max time script can take. uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields # php_value max_execution_time 200 # 6. set max time for input to be recieved. Uncomment this line if you have a lot of product options or are getting errors where forms are not saving all fields # php_value max_input_time 200 # 7. disable open_basedir limitations # php_admin_value open_basedir none Цитата Ссылка на комментарий Поделиться на других сайтах Больше вариантов поделиться...
Pelmen Опубликовано: января 11, 2017 Автор Жалоба Поделиться Опубликовано: января 11, 2017 Есть предположение, что работает во эта строка: RewriteRule ^([^?]*) index.php?_route_=$1 [L,QSA] жду информации Цитата Ссылка на комментарий Поделиться на других сайтах Больше вариантов поделиться...
Рекомендуемые сообщения
Присоединяйтесь к обсуждению
Вы можете опубликовать сейчас и зарегистрироваться позже. Если у вас есть учётная запись, войдите, чтобы публиковать под своей учётной записью.