If you have installed Magento 2 into a subdirectory (/store
, for example) then you should adjust your webserver.
If you webserver is Apache then you can do the adjustment through the 4 Magento 2 .htaccess
files:
.htaccess
Find the RewriteEngine on
line:
Place the following code right after the line above:
RewriteCond %{REQUEST_URI} !^/store/
RewriteRule ^(.*)$ /store/$1
Replace store
with your subdirectory path.
ea430
(ea430)
December 25, 2015, 9:42am
2
How settings should be for subdomain?
Can you give an example?
You should navigate the standard Magento 2 .htaccess
files and just do that I described above.
ea430
(ea430)
December 25, 2015, 10:08am
4
But how?
address domains
shop.qupple.net (shop subdomain)
Can you share accordingly.
I’m a rookie.
You should not specify a domain in the .htaccess
files. You should specify the subfolder only. See the top post: the subfolder is /store/
in my case.
Drogon
(Drogon)
January 18, 2016, 2:25pm
6
What is your full path/directory ? where is /store/ located ?
The /store/
is not a folder: it is a path in the store’s URLs.
Please see the RewriteCond
and RewriteRule
documentation.