When you’re designing the frequently asked questions page for your website, keeping user experience at the top of your mind is essential. Visitors are looking for answers as quickly as possible, and the way you design your page has a big influence on it. If the frequently asked questions are limited in amount, you can easily showcase them below each other. But, if you have many questions that need answering, grouping them might be more beneficial. In today’s Divi tutorial, we’ll show you how to structure them in custom clickable tabs. You’ll be able to download the JSON file for free as well!
Let’s get to it.
Download The Layout for FREE
To lay your hands on the free layout, you will first need to download them using the button below. To gain access to the download you will need to subscribe to our Divi Daily email list by using the form below. As a new subscriber, you will receive even more Divi goodness and a free Divi Layout pack every Monday! If you’re already on the list, simply enter your email address below and click download. You will not be “resubscribed” or receive extra emails.
Join the Divi Newsletter and we will email you a copy of the ultimate Divi Landing Page Layout Pack, plus tons of other amazing and free Divi resources, tips and tricks. Follow along and you will be a Divi master in no time. If you are already subscribed simply type in your email address below and click download to access the layout pack.
You have successfully subscribed. Please check your email address to confirm your subscription and get access to free weekly Divi layout packs!
1. Build the Element Structure
Add Section #1
Start by adding a new section to the page you’re working on. Open the section settings and apply a background color.
Next, apply a custom border.
Box Shadow
Include a box shadow as well.
Z Index
And complete the section settings by increasing the z index in the advanced tab.
Continue by adding a new row to the section using the following column structure:
Add some custom spacing values next.
Add Text Module to Column
Add H1 Content
Time to add modules, starting with a Text Module containing some H1 content of your choice.
H1 Text Settings
Change the module’s H1 text settings accordingly:
Add Divider Module to Column
And complete the module settings by adding some top margin to the spacing settings.
On to the next row. Use the following column structure:
Remove all default top and bottom padding too.
Add Text Module #1 to Column
Add H3 Content
Add a first Text Module to the row with some H3 content of your choice.
Background Color
Add a white background color.
H3 Text Settings
Then, modify the H3 text settings accordingly:
Include a box shadow as well.
Main Element CSS
And complete the module settings by assigning a custom display property to the module’s main element in the advanced tab. This, in combination with the adjusted width, will allow several modules to show up next to each other.
Clone Text Module 3x
Once you’ve completed the first Text Module, you can clone it three times.
Change Content
Make sure you change the content in each one of the duplicates.
Add another section right below the previous one, open the section settings and apply some top and bottom padding.
Continue by adding a new row using the following column structure:
Open the row settings, go to the design tab and change the sizing settings as follows:
Add Toggle Module #1 to Column
Add Content
Then, add a first Toggle Module to the row and use some content of your choice.
Icon Settings
Move on to the module’s design tab and change the icon settings.
Toggle Settings
Modify the toggle settings too.
Title Text Settings
Then, apply some custom styles to the title.
Closed Title Text Settings
We’re changing the closed title text color too.
Body Text Settings
Then, we’ll style the body text.
Next, we’ll change the border color.
Toggle Content CSS
And we’ll complete the module settings by adding one line of CSS code to the toggle content area in the advanced tab.
Clone Toggle Module as Many Times as Wanted
Once you’ve completed the first Toggle Module, you can clone it as many times as you want.
Change Content
Make sure you change all duplicate content.
Change State of Toggle Module #1
Then, open the first Toggle Module again and change the state to “Open”.
Clone Entire Row 3x
Now that we have our first set of Toggle Modules, we can clone the entire row three times. In total, we’ll now have 4 rows containing Toggle Modules. This matches the number of Text Modules in the second row of section #1.
Change Content
Make sure you change the content in each duplicate row.
Add Functionality
Add Consecutive CSS IDs to Text Modules in Row #2 of Section #1
Now that we have all elements in place, it’s time to apply the functionality. We’re going to make sure that once a Text Module in row #2 of section #1 is clicked, the corresponding FAQ toggles are shown. Open each one of the Text Modules individually and use the following consecutive CSS IDs:
Add Consecutive CSS IDs to Rows in Section #2
Next, we’ll apply CSS IDs to each row containing Toggle Modules. We’re following the same consecutive order.
Add Code Module to Row #1 of Section #1
To make the functionality works, we’ll use some custom CSS and JQuery code. To add the code to our page, we’ll insert a new Code Module in row #1 of section #1, right below the Divider Module. Make sure you add style and script tags in advance.
Add CSS Code
Then, copy paste the following CSS code between the style tags:
Add JQuery Code
And complete the tutorial by using the following lines of JQuery code between the script tags:
Now that we’ve gone through all the steps, let’s take a final look at the outcome across different screen sizes.
In this post, we’ve shown you how to improve your frequently asked questions page’s user experience. More specifically, we’ve shown you how to structure the questions in different tabs per type. This approach will help you organize your frequently asked questions, which in turn will help your visitors find answers to their questions quicker. You were able to download the JSON file for free as well! If you have any questions, feel free to leave a comment in the comment section below.
If you’re eager to learn more about Divi and get more Divi freebies, make sure you subscribe to our email newsletter and YouTube channel so you’ll always be one of the first people to know and get benefits from this free content.
This content was originally published here.