Discourse-home-page

discourse-home-page

This Discourse plugin allows to set any existing Discourse page (a topic, a category, etc.) as the home page of your Discourse instance.

The repo is here:

https://github.com/sylque/discourse-home-page

This plugin is especially useful when used with DiscPage.

Settings

  • discourse_home_page_enabled : set to true to enable the plugin

  • discourse_home_page_path : path of the home page. For example /t/12 will set the home page to topic 12 and /c/5 will set the home page to category 5.

    **** EDIT, NEW FEATURE:

    You can support localized home pages by adding more values to
    discourse_home_page_path. For example, the following will redirect
    French-speaking users (as detected by Discourse) to topic 13,
    German-speaking users to topic 14 and all other users to topic 12.

      /t/12
      fr,/t/13
      de,/t/14
    

Drawback

When the home page points to a topic, the url in the address bar is changed to the topic url.

Example: if your Discourse url is www.mydiscourse.org and you set the home page to /t/mytopic/12 , then any user coming to www.mydiscourse.org will see www.mydiscourse.org/t/mytopic/12 in the address bar.

Warning

This plugin ia based on a hack. There is no certainty it will keep working in future versions of Discourse, even though I’ll do my best to maintain it.

There is this line in Discourse which might cause an issue, but I couldn’t get my Discourse instance to run through it. Please let me know if you can.

16 个赞

Thanks and I have another question is!
How to set homepage like this https://meta.discourse.org/
Currently the homepage I am displaying new posts and categories such as Categories - Discourse Meta

2 个赞

That can be achieved by setting your homepage to Latest Topics. You can make that change my running your site’s setup wizard again and selecting Latest Topics in the Hompage step. Specifically, go to /wizard/steps/homepage to see this step. You won’t need a plugin to set this.

3 个赞

Hi @Bcat.

If your question is “How do I set my home page to Latest Topics”, then see @osioke’s answer above.

If your question is “How do I set my home page to an external website”, then the answer is: it is not possible using this plugin.

3 个赞

Thanks a lot, so it’s located /wizard/steps/homepage before I kept looking at settings.

2 个赞

Hello,

I am a newbie from France, I can’t find How to set homepage like this Categories - Discourse Meta

If you need to set the category page as your home page, I believe this plugin is not required. Just run the Discourse wizard (https://forum.yourdomain.com/wizard) and change the Homepage combo box.

1 个赞

您好!我使用的是 v3.1.0 版本,这个插件直到上周都运行得非常完美。我没有更改任何设置,但现在无法将任何新帖子推广为精选。有什么我可以排查的地方吗?谢谢 :slight_smile:

1 个赞

看起来插件有更新。您可以通过访问您网站上的 /admin/plugins 来查看您是否拥有最新版本。版本列中是否显示 05c0098?

2 个赞

你好 @victoria1。我在 Discourse 3.3.0.beta1-dev 版本和 Discourse-home-page 1.0.6 版本下没有遇到任何问题。你使用的是哪个版本的插件?(请按照 @jericson 的建议检查 /admin/plugins

3 个赞

我意识到此插件的最新版本(>= 1.0.5)可能与旧版 Discourse 不兼容。您能否提供您的论坛地址?(无需完全访问权限,公开登陆页面即可)这样我就可以更好地查看。

2 个赞

感谢您的关注!:folded_hands:

1 个赞

@victoria1,我已部署了插件的新版本(v1.0.7),希望它能解决您的问题。请尝试一下并告知我。

(供参考,该问题已在此处跟踪)

3 个赞

哇,太棒了!非常感谢你,@syl:pray:

看起来我带有“featured”标签的帖子有 2/3 的显示出来了。我正在尝试找出第 3 个帖子有什么不同。所有帖子都至少有 1 张图片用作缩略图,并且我尝试过移除并重新添加该标签。

1 个赞

@victoria1discourse-home-page 插件与“精选”帖子无关。您确定您的问题是由此插件引起的吗?

我也这么认为,但很高兴我错了 :sweat_smile:

“featured”标签只是我为 discourse-home-page 插件选择帖子时使用的标签!

嗯,这正是我所想的:这个帖子是关于 discourse-home-page 插件的,而您的问题与 discourse-homepage-feature-component 插件有关 :slight_smile: 所以您可能想在这里提问:https://meta.discourse.org/t/homepage-feature/144264

1 个赞

啊!是的。感谢您的时间,很抱歉浪费了您的时间 :pray:

1 个赞