> ## Content Index
> Fetch the complete content index at: https://getpublii.com/docs/llms.txt
> Use this file to discover other available public pages before exploring further.

# The Hyvor Talk Plugin

- URL: https://getpublii.com/docs/hyvor-talk-plugin.html
- Published: 2022-04-10T14:12:12.880Z
- Updated: 2026-08-18T09:00:07.600Z
- Description: Hyvor Talk is a hosted commenting platform with moderation, customization, spam protection, and privacy controls. The Hyvor Talk Comments plugin adds its comment section to…
- Author: Publii Team
- Tags: plugins

[Hyvor Talk](https://talk.hyvor.com/) is a hosted commenting platform with moderation, customization, spam protection, and privacy controls. The Hyvor Talk Comments plugin adds its comment section to Publii posts and pages.

You need a Hyvor Talk account and the Website ID assigned to your site. The plugin uses the current Hyvor Talk v3 embed and gives each Publii post or page a stable identifier, so its comment thread remains connected if the page URL changes.

## Adding Comment Plugin Support to Older or Custom Themes

Current Publii themes include support for comment plugins. Follow this section only if you use an older theme or a custom theme that does not include the `commentsCustomCode` helper.

1.  Open your file manager and go to `Documents/Publii/sites/YOUR_SITE/input/themes/YOUR_THEME`. Replace `YOUR_SITE` with your site's folder name and `YOUR_THEME` with the active theme's folder name.
2.  Open the theme's `post.hbs` file in a code editor.
3.  Near the end of the file, find the old comments block. It may look like this:

    ```html
    {{#if @config.post.displayComments}}
        <div class="post__comments">
            <div class="wrapper">
                <h2 class="h5">{{ translate 'post.comments' }}</h2>
                {{> disqus}}
            </div>
        </div>
    {{/if}}
    ```

    Replace it with:

    ```html
    {{#if @config.post.displayComments}}
        <div class="post__comments">
            <div class="wrapper">
                {{{@commentsCustomCode}}}
            </div>
        </div>
    {{/if}}
    ```

4.  Save the file.

Keep a backup of custom theme changes. A theme update can replace edited theme files.

## Activating the Plugin

1.  Open **Tools & Plugins** in Publii.
2.  Find **Hyvor Talk Comments** and enable its switch.
3.  Click the plugin card to open its options.
4.  Enter your **Website ID**, review the remaining settings, and save the changes.
5.  Regenerate the website after changing the plugin configuration.

## Finding Your Hyvor Talk Website ID

1.  Create an account on the [Hyvor sign-up page](https://hyvor.com/signup), or sign in to an existing account.
2.  Open the [Hyvor Talk Console](https://talk.hyvor.com/console) and add your website.
3.  Open the website's installation page. Hyvor displays an embed containing a `website-id` value.
4.  Copy that value into the plugin's **Website ID** field. Copy the number only, without quotation marks or other embed code.

The Website ID can contain more than four digits. Use the full value shown in the Hyvor Talk Console.

## Enabling Comments in Your Theme

The plugin supplies the comment box, while the theme decides where Publii can display it.

To enable comments for posts or pages across the site, open **Theme** and go to **Custom Settings** → **Post Options** or **Page Options**. Enable **Display Comments**.

You can also control comments for one post or page. Open the item in the editor, click the settings icon, choose **Other Options**, and change **Display Comments**.

## Hyvor Talk Comments Plugin Options

The options below let you connect the plugin to your Hyvor Talk website, adjust the comments section to match your theme, control when it loads, and configure Publii cookie consent. Most users only need to enter the Website ID and can keep the default values for the remaining settings.

### Comments Configuration

-   **Website ID** – The ID assigned to your website in the Hyvor Talk Console. Comments cannot load without it.

### Appearance

-   **Comments heading** – Text shown above the comment section. Leave the field empty to hide the heading.
-   **Heading level** – The HTML heading level used for the title. `H2` suits most themes, but you can choose `H3` through `H6` to match the page structure.

### Messages

-   **JavaScript disabled message** – Text shown when a visitor has disabled JavaScript in the browser.

### Advanced Styling

These fields are intended for theme developers. Keep their default values unless your theme requires different CSS classes.

-   **Outer container CSS class** – Sets the class on the outer element surrounding the comment section. The default value is `comments`.
-   **Inner container CSS class** – Sets the class on the inner comment container. The default value is `comments-wrapper`.
-   **Heading CSS class** – Adds a CSS class to the comments heading. Leave it empty to use the theme's standard heading style.

### Loading

-   **Load comments when visible** – Delays Hyvor Talk until the visitor scrolls near the comment section. This reduces the work performed during the initial page load. Disable this option if you want the comment section to start loading with the page.

### Cookie Banner Integration

-   **Require cookie consent** – Prevents the browser from downloading the Hyvor Talk script until the visitor accepts the selected Publii cookie group.
-   **Cookie Group ID** – The internal Group ID configured in **Site Settings** → **Privacy Settings** → **Cookie Groups**. Enter the same value in both places, for example `comments`.
-   **Message before consent** – Text shown where the comment section would appear until the visitor accepts the selected cookie group.

## Configuring Cookie Consent

Use these steps if you enable **Require cookie consent** in the plugin:

1.  Open **Site Settings** → **Privacy Settings**.
2.  Enable the cookie banner and its advanced cookie configuration.
3.  Add Hyvor Talk to a suitable group, such as a functionality or comments group.
4.  Give that group a Group ID, for example `comments`. Use letters, numbers, hyphens, or underscores without spaces.
5.  Return to the Hyvor Talk Comments plugin and enter the exact same value in **Cookie Group ID**.
6.  Save the settings and regenerate the website.

Do not leave **Cookie Group ID** empty while **Require cookie consent** is enabled. The plugin will keep Hyvor Talk blocked because it cannot determine which consent should unlock the script.

Read [Publii's cookie banner guide](https://getpublii.com/docs/gdpr-cookie-banner-configuration.html#doesyoursiteuseanyexternalscripts) for details about external scripts and cookie groups.

## Page Identification and Existing Comment Threads

Hyvor Talk uses a page identifier to connect each page with its comment thread. The plugin sets this identifier from the Publii post or page ID and also supplies the current page URL. You do not need to enter a `page-id` value in the plugin settings.

The previous Publii plugin also used the Publii post or page ID. Version 3 keeps that identifier when it switches to Hyvor Talk's current `page-id` attribute, so existing threads should remain connected after the update. If you previously used custom embed code with a different identifier, follow [Hyvor Talk's v3 migration guide](https://talk.hyvor.com/docs/migrate-v3).

## Preview Mode

Publii does not load the live Hyvor Talk embed in preview mode. The preview displays a notice in its place. Generate or synchronize the site and open the published page to test the comment form and cookie consent flow.

## Troubleshooting

-   **No comment section appears** – Confirm that the plugin is enabled, the Website ID is present, and **Display Comments** is enabled for the current content type or item.
-   **The consent message remains visible** – Confirm that the Cookie Group ID in the plugin matches the Group ID in Privacy Settings, including capitalization.
-   **Comments do not appear in Publii Preview** – Test the generated or published page. The plugin skips the external Hyvor script in preview mode.
-   **A page shows a new empty thread** – Check whether custom code or an older integration used a different Hyvor page identifier. Match the old identifier to the current Publii page ID or migrate the thread in Hyvor Talk.

For Hyvor's embed settings and current platform behavior, see the [Hyvor Talk installation guide](https://talk.hyvor.com/docs/install) and [comments embed documentation](https://talk.hyvor.com/docs/comments).
