Accordion Item

The Accordion Item A collection of fields that describe a specific type of content, like a news article, a person, or an event. Site admins can add additional content types by enabling optional modules. WDS can also create custom content types for a site. is used to input individual accordion items which are displayed on your site using an Accordion Item List Block. Unlike most content types, Accordion Items do not have a detail page and do not show up as individual results in your website's search engine. They are only meant to be used in conjunction with the list block.

Enable the Accordion (Advanced) A collection of features or functionality that can be enabled on sites. WDS has made several optional modules available to site administrators to enable on their site. For example, the "News" module enables the News content type and provide a News List Block for displaying news on a page.

The Accordion (Advanced) module must be enabled before you can use this content type.

Simpler Alternative

There is another, simpler option for adding accordions to your pages: The Simple Accordion Block provided via the Accordion (Simple) module. This simpler option allows you to specify all accordion items to display in a single form. You should only use the more advanced Accordion Item content type if any of the following are true:

  • You want to share Accordion Items across multiple different accordion lists. For example, you may have several FAQ-style accordions for different topics, and some of the topics share a common item. The Accordion Item content type allows you to share the items without repeating the item text for each accordion.
  • You have many accordion items and use categorization and would like visitors to filter the accordion items list by category. The Accordion Item list block supports this, but the simpler Simple Accordion block does not.
  • You have many accordion items and want to import them from a CSV file. This is helpful if you want to enter all your accordion item content in a spreadsheet and then upload it all at once.

Adding Accordion Items

Individual accordion items can be added manually or imported from a CSV file.

Manually Adding Items

As a logged in content author, content manager, or site admin, visit Content > Add Content > Accordion Item.

In the main area of the form on the left, you'll find some important fields to fill out:

  • Title: The accordion item title. This is what visitors will click to expand to see the full content.
  • Content: The content that will be shown when this accordion item is expanded.

On the right sidebar, you'll find additional fields:

  • Categorization: Used to categorize your Accordion Items. See Content Categorization learn about managing the available categories. These categories are used when creating Accordion Item List blocks on your site.
  • Authoring information: Contains content creator user and date/time of when the content was created.
  • Promotion options: This is used if displaying a Accordion Item List block to stick the item at the top of the list.

Use the Save button at the bottom of the form to save the accordion item. The Published checkbox can also be used to control public visibility. If unchecked, visitors to your site will not be able to view the contents, even if it's included in a list block.

Importing Items from a CSV File

Use your favorite spreadsheet application to input the accordion items you want to import. Each row in the sheet should represent one accordion item. The first column is used for the title, the second column the content, and an optional third column can contain a comma-separated list of categories to assign to that item:

Spreadsheet showing the desired format for the accordion item import

After entering the items:

  1. Export the spreadsheet to a CSV file and save to your computer somewhere.
  2. Visit the content dashboard at /admin/content
  3. Click the "Import accordion items" button
  4. Select the CSV file you created
  5. If you added a header row to your CSV, check the box indicating so. Otherwise the header row will be imported as if it were an accordion item.
  6. Press Import

Displaying Accordion Items

Accordion Items can be displayed on a Page layout using an Accordion Item List Block.