Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
2 Websites with same Vanilla database?
Hi
I want to run 2 separate websites using different domains but pointing to the same Vanilla database. Is this possible? Can someone provide instructions on how to setup?
Thanks in advance...
I want to run 2 separate websites using different domains but pointing to the same Vanilla database. Is this possible? Can someone provide instructions on how to setup?
Thanks in advance...
0
Best Answer
-
x00 MVPyou need to point the domain to the same site.
well search engines don't like duplicated content so you a going to need to do a 301 redirect, which you can do with .htaccess
I kind of think you are approaching this wrong though. What you want to do isn't a good idea generally.grep is your friend.
0
Answers
There was an error rendering this rich post.
This isn't a federated software. You could run two different set-ups with the same database, but I'm not sure what the point is. I think what you are trying to do may be best served at server level rather than app/framework level.
grep is your friend.
http://nepali.im and http://supernepal.com
But this is temporary, as I am in the process of switching my domain from http://nepali.im to http://supernepal.com.
What is it that you are trying to do? Google doesn't like duplicate contents. So hosting the same site on two domains isn't a good idea, unless you know better.
How can I achieve this?
Vanilla Forums COO [GitHub, Twitter, About.me]
@nagrapnagrap changing the theme on the fly should be possible, it is already done with mobile.
If you override the Theme() function.
stripos(stripos(Gdn::Request()->RequestHost(),'mydomain.com')!==FALSE
will match mydomain.com, You need to set ThemeAlt in config.I'd avoid editing the core directly.
You also have the
AfterAnalyzeRequest
hook, you could set the theme on the fly there.grep is your friend.
There was an error rendering this rich post.
if(!function_exists('Theme')) {
grep is your friend.
If I make the above changes as per your comments, then do I also have to setup my hosting to redirect to one of the URLs?
Currently, say if I have domain xyz.com already setup with Vanilla, but domain abc.com has not been setup at all. Then what other changes do I have to make to domain abc.com so it uses a different theme but points to the same database as domain xyz.com? Is there any changes required within a configuration file?
well search engines don't like duplicated content so you a going to need to do a 301 redirect, which you can do with .htaccess
I kind of think you are approaching this wrong though. What you want to do isn't a good idea generally.
grep is your friend.
grep is your friend.