Configuring the Questions Widget

Liferay DXP/Portal 7.3+

There are two primary methods for configuring the Questions widget: directly through the widget configuration and through the System Settings configuration.

To configure through the widget configuration,

  1. Start editing the page where the Questions widget has been deployed.

  2. Click Options (Widget Options icon) in the widget header → Configuration.

    Configure the widget through the Options menu.

    Tip

    Before Liferay DXP 2025.Q1, the Configuration option was located in the widget’s top-right corner.

To configure through System Settings,

  1. Navigate to Control PanelSystem SettingsMessage Boards.

  2. Click on Questions under Widget Scope.

    Navigate to the Questions widget settings in system settings.

Topic Display Style

Topics can be displayed as cards or as a list.

  1. Click Options (Widget Options icon) in the widget header → Configuration.

    Note

    Before Liferay DXP 2025.Q1, the Configuration option appeared in the widget’s top-right corner.

  2. Under General Settings, there is a Show Cards for Topic Navigation option.

If this is checked, the widget displays separate cards for each question topic. If it is not checked, the widget displays a list of all the questions.

The configuration window opens with different options.

Limiting Topic Display

Questions default display behavior is to show all Topics. You can opt to only display certain topics by configuring a Root Topic. To only display specific sub-topics or questions do the following,

  1. Click Options (Widget Options icon) in the widget header → Configuration.

    Note

    Before Liferay DXP 2025.Q1, the Configuration option appeared in the widget’s top-right corner.

  2. Click Select under Root Topic ID.

    Select an individual topic as the root topic.

  3. Select a topic and click Save. The widget now only shows sub-topics and questions for the selected topic.

Managing Widget Permissions

  1. Click Options (Widget Options icon) in the widget header → Permissions.

    Note

    Before Liferay DXP 2025.Q1, the Permissions option appeared in the widget’s top-right corner.

  2. A new window opens.

    Assign permissions for different roles on this page.

  3. Assign permissions for different Roles. Click Save.

Redirecting Guest Users to Login

To enable this functionality you must configure it through System Settings,

  1. Navigate to Control PanelSystem SettingsMessage Boards.

  2. Click Questions under Widget Scope.

    Navigate to the Questions widget settings in system settings.

  3. Check Enable Redirect to Login

  4. Guests user are now redirected to a login page when they try to click Ask Question.

Note

A Service Access Policy must be created to allow Guest users to view the widget.

Creating a Service Access Policy to Allow Guest Viewers

  1. Navigate to Control PanelService Access Policy. Click on the Add icon (Add icon).

  2. Give the policy a Name and Title. Click the Switch to Advanced Mode button at the bottom. Add the following two signatures under Allowed Service Signatures,

    com.liferay.message.boards.service.MBCategoryService#getCategoriesCount
    com.liferay.message.boards.service.MBCategoryService#getCategory
    

    Create a new policy and add the signatures.

  3. Click Save to save the new policy.

System Configuration Reference

SettingDescription
Show Cards for Topic NavigationIf this is checked, the widget displays separate cards for each question topic. Otherwise, it displays a list of all the questions.
Use Topic Names in URLIf this is checked, each topic name is used in a more friendly URL instead of a topic ID number.
Root Topic IDThis setting is ignored.

Capabilities

Product

Education

Contact Us

Connect

Powered by Liferay
© 2024 Liferay Inc. All Rights Reserved • Privacy Policy