Hello everyone!
I am currently developing a module for my site that will allow me to classify each solution to help a disability by type.
Here's an example:
Type : Visual disability
Solution : Add screen readers
For this, I have my database in which these types and solutions are found. In this database, the solutions of one type or another are not in a defined order. They can be put at random, when a user adds one.
I need to display, in a table, these types first (as a title), then the solutions corresponding to this type.
I manage to generate a display thanks to a foreach loop, but my solutions are all mixed and therefore not clearly sorted.
Here is how it is currently displayed
Visual disability
Audio-described cut-scenes
Highlighted path to follow
Sensitivity settings for all the controls
Screen readers on menus
Slow down the game speed
But I would need it to look like this:
Visual disability
Audio-described cut-scenes
Highlighted path to follow
Screen readers on menus
Slow down the game speed
Physical disability
Sensitivity settings for all the controls
In my example above, only the solution "Sensitivity settings for all the controls" is part of the "Physical disability" type. The rest is part of the "Visual disability" type.
Here is the code I currently use to retrieve my information from my database and display it. It is a WordPress associated with data coming from MetaBox.
https://pastebin.com/embed_iframe/bxsuN2NW?theme=dark
Thank you in advance for all the help you can give me!