admin管理员组文章数量:1394173
I have a website let's say mysite (with it's own database that I created through plesk) and i have created a subdomain with the name sub.mysite.
After trying to install wordpress on my subdomain, I figured that I can't create a second database from Pesk as my hosting does no allow this through my subscription.
Can I use the same database that I use at mysite also to my subdomain, just creating a new database user, or I will destroy the current database?
I have a website let's say mysite (with it's own database that I created through plesk) and i have created a subdomain with the name sub.mysite.
After trying to install wordpress on my subdomain, I figured that I can't create a second database from Pesk as my hosting does no allow this through my subscription.
Can I use the same database that I use at mysite also to my subdomain, just creating a new database user, or I will destroy the current database?
Share Improve this question edited Apr 4, 2020 at 11:00 fuxia♦ 107k39 gold badges255 silver badges459 bronze badges asked Apr 4, 2020 at 10:56 CornholioCornholio 212 bronze badges1 Answer
Reset to default 1Can I use the same database that I use at mysite also to my subdomain
Yes, as long as the table names don't clash you're fine, some people have multiple WP instances using the same database, but with different table prefixes.
However, keep in mind that there is a security risk as now 2 sites have access to eachothers data.
or I will destroy the current database?
If you run a destructive query yes! But why would you do that.
I don't think you have anything to fear here, but, it would be much easier to just create a local dev environment and test it out. This would give you the confidence and a practice run to do it in production
本文标签: Using same database for main and subdomain
版权声明:本文标题:Using same database for main and subdomain 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744598159a2614903.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论