I've a purchased a hosting plan from hostinger, but it seems they don't provide wild card subdomains. Now I want to set up a multisite wp on hostinger in a subdomain format, not sub directories. When I set up multisite as sub-directories, it works fine, but it is not working for Subdomain format. I think it can be fixed by modifying the htaccess. Need your help to fix this. Here is the domain structure -
Parent domain - example [ Directory - user/domains/example/public_html/(wp files)]
Sub domain - abc.example [Directory - user/domains/example/public_html/abc]
Now if a request comes to abc.example, how can I redirect the request to parent domain so that WP can recognize and serve the files as Multisite.
example .htaccess -
# BEGIN WordPress
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
# add a trailing slash to /wp-admin
RewriteRule ^wp-admin$ wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^(.*\.php)$ $1 [L]
RewriteRule . index.php [L]
# END WordPress
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745279601a4620215.html
评论列表(0条)