Post by rosenkaradakov » Thu Apr 20, 2017 10:37 pm

Здравейте!
Имам проблем с url-те, не мога да ги направя нормални. До преди две седмици всичко си беше наред. Но сега забелязах, че вече не са така. Не знам дали не е от https който сложих или от нещо друго, но не се сещам да съм правил други промени. XML файла, който ползвам е този:

<modification>

<id>Change-Index-PHP-route</id>
<version>1.0.0</version>
<vqmver>2.1.5</vqmver>
<author>anung</author>

<file name="catalog/controller/common/seo_url.php">
<operation>
<search position="before"><![CDATA[elseif (isset($this->request->get['path']))]]></search>
<add><![CDATA[
} elseif ($this->request->get['_route_'] == 'wishlist') {
$this->request->get['route'] = 'account/wishlist';
} elseif ($this->request->get['_route_'] == 'contact') {
$this->request->get['route'] = 'information/contact';
} elseif ($this->request->get['_route_'] == 'account') {
$this->request->get['route'] = 'account/account';
} elseif ($this->request->get['_route_'] == 'sitemap') {
$this->request->get['route'] = 'information/sitemap';
} elseif ($this->request->get['_route_'] == 'manufacturer') {
$this->request->get['route'] = 'product/manufacturer';
} elseif ($this->request->get['_route_'] == 'affiliates') {
$this->request->get['route'] = 'affiliate/account';
} elseif ($this->request->get['_route_'] == 'special') {
$this->request->get['route'] = 'product/special';
} elseif ($this->request->get['_route_'] == 'login') {
$this->request->get['route'] = 'account/login';
} elseif ($this->request->get['_route_'] == 'logout') {
$this->request->get['route'] = 'account/logout';
} elseif ($this->request->get['_route_'] == 'register') {
$this->request->get['route'] = 'account/register';
} elseif ($this->request->get['_route_'] == 'cart') {
$this->request->get['route'] = 'checkout/cart';
} elseif ($this->request->get['_route_'] == 'checkout') {
$this->request->get['route'] = 'checkout/checkout';
} elseif ($this->request->get['_route_'] == 'returns') {
$this->request->get['route'] = 'account/return/insert';
} elseif ($this->request->get['_route_'] == 'returns') {
$this->request->get['route'] = 'account/return/insert';
} elseif ($this->request->get['_route_'] == 'vouchers') {
$this->request->get['route'] = 'account/voucher';
} elseif ($this->request->get['_route_'] == 'newsletter') {
$this->request->get['route'] = 'account/newsletter';
} elseif ($this->request->get['_route_'] == 'order-history') {
$this->request->get['route'] = 'account/order';
} elseif ($this->request->get['_route_'] == 'forgotten-password') {
$this->request->get['route'] = 'account/forgotten';
} elseif ($this->request->get['_route_'] == 'your-downloads') {
$this->request->get['route'] = 'account/download';
} elseif ($this->request->get['_route_'] == 'transactions') {
$this->request->get['route'] = 'account/transaction';
} elseif ($this->request->get['_route_'] == 'returns') {
$this->request->get['route'] = 'account/return';

]]></add>
</operation>
<operation>
<search position="before"><![CDATA[$key == 'path']]></search>
<add><![CDATA[
} elseif (isset($data['route']) && $data['route'] == 'common/home') {
$url .= '/';
} elseif (isset($data['route']) && $data['route'] == 'account/wishlist' && $key != 'remove') {
$url .= '/wishlist';
} elseif (isset($data['route']) && $data['route'] == 'information/contact') {
$url .= '/contact';
} elseif (isset($data['route']) && $data['route'] == 'account/account') {
$url .= '/account';
} elseif (isset($data['route']) && $data['route'] == 'information/sitemap') {
$url .= '/sitemap';
} elseif (isset($data['route']) && $data['route'] == 'product/manufacturer') {
$url .= '/manufacturer';
} elseif (isset($data['route']) && $data['route'] == 'affiliate/account') {
$url .= '/affiliates';
} elseif (isset($data['route']) && $data['route'] == 'product/special' && $key != 'page' && $key != 'sort' && $key != 'limit' && $key != 'order') {
$url .= '/special';
} elseif (isset($data['route']) && $data['route'] == 'account/login') {
$url .= '/login';
} elseif (isset($data['route']) && $data['route'] == 'account/logout') {
$url .= '/logout';
} elseif (isset($data['route']) && $data['route'] == 'account/register') {
$url .= '/register';
} elseif (isset($data['route']) && $data['route'] == 'checkout/cart') {
$url .= '/cart';
} elseif (isset($data['route']) && $data['route'] == 'checkout/checkout') {
$url .= '/checkout';
} elseif (isset($data['route']) && $data['route'] == 'account/return/insert') {
$url .= '/returns';
} elseif (isset($data['route']) && $data['route'] == 'account/voucher') {
$url .= '/vouchers';
} elseif (isset($data['route']) && $data['route'] == 'account/newsletter') {
$url .= '/newsletter';
} elseif (isset($data['route']) && $data['route'] == 'account/order') {
$url .= '/order-history';
} elseif (isset($data['route']) && $data['route'] == 'account/forgotten') {
$url .= '/forgotten-password';
} elseif (isset($data['route']) && $data['route'] == 'account/download') {
$url .= '/your-downloads';
} elseif (isset($data['route']) && $data['route'] == 'account/transaction') {
$url .= '/transactions';
} elseif (isset($data['route']) && $data['route'] == 'account/return') {
$url .= '/returns';

]]></add>
</operation>
</file>
</modification>

А това ми е htaccess:

Options +FollowSymlinks

Options -Indexes

<FilesMatch "\.(tpl|ini|log)">
Order deny,allow
Deny from all
</FilesMatch>

# SEO URL Settings
RewriteEngine On
RewriteBase /
RewriteRule ^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]

# Редирект c www на без www
RewriteCond %{HTTP_HOST} ^www\.(.+)$
RewriteRule ^(.*)$ https://%1/$1 [R=301,L]
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
RewriteCond %{HTTP_USER_AGENT} libwww-perl.*
RewriteRule .* – [F,L]
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.php\ HTTP/
RewriteRule ^index\.php$ https://sportfaster.com/ [R=301,L]

Ще се радвам някой да помогне.


Posts

Joined
Thu Apr 20, 2017 10:34 pm
Who is online

Users browsing this forum: haonamn082 and 5 guests