I have successfully installed subsite module in my main site, but when I created subdomain from cpanel it gives me 500 error.
We've moved the forum!
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
- Page 11(current)
- 2
- Next 10 entries
CPanel does funny things. It's probably related to either permissions, folder heirarchy, or both.
It would be better if we knew what the error was. You'll need to check your logs for that.
Hi
Sounds like you'd be better off talking to your hosting company and getting access to your error logs.... Subsites works fine in general, but of course your current setup in cpanel might not be compatible with it.
Nicolaas
Thanks for the quick reply.
I think silverstripe default htaccess need some modification, but what is the code I need to add in htaccess file?
It is first time that I am using subdomain with silverstripe.
error_log says- client denied by server configuration: /public_html/subdomainfolder/.htaccess
When I tried with http://www.mydomain.com/?SubsiteID=3, it works fine.
How can make it to work like http://subdomain.mydomain.com
Hi VPull,
To get a subsite working on another domain, you'll need to add the domain to the subsite, which will write to the host map php file in the subsites directory.
For domain set up, you should create a cname record for the subdomain with a value of your domain.com
Basically you want to point your subdomain to the main site, then the subsites host map file will handle the direction to the correct subsite as set up through the admin.
Hope that helps.
Thanks Jack,
I think installation of subsite module is perfect, but I am confused about CNAME record.
What should I mentioned in record, there are two values NAME and CNAME? or
instead of creating CNAME record is it ok, if I create sub domains from control panel and redirect it to main domain?
I got below code when I checked host-map file
<?php
// Generated by Subsite::writeHostMap() on 11/Apr/15
$subsiteHostmap = array (
'm.mydomain.com' => 'm.mydomain.com',
);
The name should be the subdomain itself I.e "m" in m.mydomain.com and cname is the domain to which you want the subdomain to be pointed e.g. mydomain.com
The result of this should be, you type in m.mydomain.com and it loads the contents of mydomain.com while keeping m.mydomain.com in the address bar.
Your hosts map file looks fine too. Subsite module will handle the rest if you get the above domain setup right.
Thanks for quick reply Jack,
I followed your suggestion and added the m.mydomain.com as a NAME and domain.com as CNAME but getting default page as
http://m.mydomain.com/cgi-sys/defaultwebpage.cgi
will this process take a time?
- Page 11(current)
- 2
- Next 10 entries