最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

posts - a WordPress connected to 2 database

programmeradmin2浏览0评论

Is it possible that Wordpress works from two databases?

I would like the post published by web A to be reflected on web B

Web A would only affect the information in the tables

wp_postmeta
wp_posts

What I've researched is using the $wpdb Is there any way to do it? I don't know where to start

I would take your help

Is it possible that Wordpress works from two databases?

I would like the post published by web A to be reflected on web B

Web A would only affect the information in the tables

wp_postmeta
wp_posts

What I've researched is using the $wpdb Is there any way to do it? I don't know where to start

I would take your help

Share Improve this question asked Aug 22, 2019 at 17:10 juanjuan 12 bronze badges 1
  • What are you trying to achieve by that precisely? – trolologuy Commented Aug 23, 2019 at 11:25
Add a comment  | 

1 Answer 1

Reset to default 0

Why don't you rather try to connect 2 wordpress to the same database ? On website B you can heavily restrain the capabilities of users. This way it will be only a sort of mirror.

Another path could be to use the rest API from website A to fuel the content from website B. Have a look on api documentation: https://developer.wordpress/rest-api/

发布评论

评论列表(0)

  1. 暂无评论