[faq_element]

This is the main shortcode for displaying the frequently asked questions (FAQ) listing section on a page.


Product


Shortcode Attributes

There are a number of shortcode attributes available which you can use to customize the output.

GENERAL LAYOUT

  1. listing_only – Enables or disables displaying only the list of questions without the accordion.
    • Default: off.
    • Options: on, off. Specify one only.
  2. display – Defines the FAQ display layout.
    • Default: image-above-content.
    • Options:
      • ORDINARY DISPLAYS: image-above-content, image-overlay-content, content-only. Specify one only.
      • SPLIT DISPLAYS: image-left-content, image-right-content. Specify 2 (Split and Split Size). Use commas to separate.
      • SPLIT DISPLAY SIZES (Required on Split Display): split-25-75, split-40-60split-50-50split-60-40. Specify 3(Split, Split Size, and Alternate Split). Use commas to separate.
      • ALTERNATE SPLIT DISPLAY (Can use only on Split-50-50 and on the opposite option of the Split Display): then-left, then-right.
  3. first_item_open – Determines whether the first accordion item is open by default.
    • Default: off.
    • Options: on, off. Specify one only.
  4. all_closed – Determines whether all accordion items are closed by default.
    • Default: off.
    • Options: on, off. Specify one only.
  5. multiple_expand – Allows multiple accordion items to be open simultaneously.
    • Default: off.
    • Options: on, off. Specify one only.
  6. deep_link – Enables deep linking support for accordion items.
    • Default: off.
    • Options: on, off. Specify one only.

DESIGN

  1. element_width – Defines the width of the element.
    • Default: default-width.
    • Options: default-width, full-width. Specify one only.
  2. alignment – Defines the alignment of the element.
    • Default: default-alignment.
    • Options: default-alignment, left, center, right. Specify one only.
  3. theme – Defines the styling theme for the element.
    • Default: default-section
    • Options: default-section, light, dark. Specify one only.
  4. background – Background image or color for the element.
    • Options: Any image URL.
  5. classes – Additional CSS classes for the element.
  6. id – Unique identifier for the element.
    • Options: Any text value.

HEADER

  1. heading – Element heading.
    • Options: Any text value.
  2. heading_size – Heading size.
    • Default: h2.
    • Options: h1, h2. Specify one only.
  3. sub_heading – Element subheading.
    • Options: Any text value.

CONTENT

  1. group_by_category – Groups questions by category.
    • Default: off
    • Options: on, off. Specify one only.
  2. image – Image for the element. Used to add image content for image-left-accordion or image-right-accordion layout.
    • Options: Any image URL.
  3. orderby – Defines the sorting order for questions.
    • Default: id.
    • Options: id, date, title, modified. Specify one only.
  4. order – Defines the sorting direction.
    • Default: ASC.
    • Options: ASC, DESC. Specify one only.

FILTER

  1. categories – FAQ Category IDs.
    • Options: Any numeric value. Use commas to separate.
  2. tags – FAQ Tag IDs.
    • Options: Any numeric value. Use commas to separate.

Example Usage

[faq_element 
    first_item_open="on"  
    multiple_expand="on" 
    deep_link="on"  
    heading="Frequently Asked Questions" 
    heading_size="h2" 
    sub_heading="Answers to Popular Questions" 
    group_by_category="on" 
    orderby="date" 
    order="DESC" 
]
Example:
This shortcode will display a FAQ section with the following features:
– The first question is expanded by default.
– Users can expand multiple questions at the same time.
– Each question has a unique URL for deep linking.
– The FAQ items are grouped by their categories.
– The questions are sorted by date, with the newest ones appearing first.
– The section has a main heading (<h2>Frequently Asked Questions</h2>) and a subheading (Answers to Popular Questions).
For the shortcode to work correctly, the faq post type must exist in the system.
The categories and tags parameters allow filtering questions by specified categories and tags.