# 将 WP Discourse 连接到运行特定版本的本地 Discourse 实例

**URL:** https://meta.discourse.org/t/connecting-wp-discourse-to-a-local-discourse-instance-running-a-specific-version/353761
**Category:** Development
**Created:** [2025年二月21日 17:31 UTC](https://meta.discourse.org/t/connecting-wp-discourse-to-a-local-discourse-instance-running-a-specific-version/353761 "2025-02-21T17:31:03Z")
**Posts on this page:** 1
**Showing post:** 8

<div class="post-metadata">

### Author: ![angus](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/angus/32/341715_2.png) [@angus](https://meta.discourse.org/u/angus)
#### Post date: [2025年二月23日 14:19 UTC](https://meta.discourse.org/t/connecting-wp-discourse-to-a-local-discourse-instance-running-a-specific-version/353761/8 "2025-02-23T14:19:31Z")

</div>

该问题与您的本地设置和网络有关。它不会是因为 Discourse 的版本，或者全局密钥和细粒度密钥之间的差异。由于您可以在本地运行 WordPress 和 Discourse 的方式和环境多种多样，因此我很难调试您的本地应用程序互连问题。以下是一些帮助您的技巧。

1. 始终运行最新版本的 Discourse、WordPress 和 [WP Discourse](https://github.com/discourse/wp-discourse) 插件。
2. 在 [WP Discourse](https://github.com/discourse/wp-discourse) 的 localhost Discourse URL 中使用端口 3000 而不是端口 4200。
3. 确保您创建的密钥可以被您设置为“发布用户名”的管理员用户名使用。

这是我的本地设置，我的本地 WordPress 和 Discourse 已相互连接。我使用 MAMP Pro 在本地运行 WordPress。

 ![Screenshot 2025-02-23 at 15.16.46](https://global.discourse-cdn.com/meta/original/4X/9/1/d/91d48f0ee6993b6edfc34fd0a4b8c58d191d7e29.jpeg)  
 ![Screenshot 2025-02-23 at 15.17.00](https://global.discourse-cdn.com/meta/original/4X/d/3/b/d3baf2178964bdd559e82014272749426a79a879.png)

---

_[View the full topic](https://meta.discourse.org/t/connecting-wp-discourse-to-a-local-discourse-instance-running-a-specific-version/353761)._
