several domains using the same core backend/frontend files
I have a few domains hosted on the same server. These domains contain very similar types of data(similar to stackoverflow.com, stackexchange.com, serverfault.com). They all have the same idea, except minor things are different like images, titles, etc.
How can I use the same base code(like a php/javascript include, or even database) on each of these domains without copy/paste and having many copies to update when i make a change?
any advice would b开发者_如何学运维e great!
edit: for a novice like myself in this department, where would I look to set variables in the virtual host which would tell the code which template/database my code should use for my specific host?
What kind of server setup or access would i need to have for this to be configured properly?
I am using PHP and MySQL for my sites.
If a thorough answer cannot be supplied, direct me as to how I can contact my hosting provider in such a way that they can understand and help me configure what I desire!
Set a variable in the virtual host that tells the code which template, database, etc. the code should use for that specific virtual host.
精彩评论