YAQ - Yet Another Quiz Extension
A Free Quiz Component for Joomla 4YAQ is a free open-source quiz extension for Joomla 4 developed by Kevin Olson for this website, Kevin's Guides.
You can use it to create review quizzes, tests, exams, etc. on your Joomla 4 powered website with relative ease.
Currently, this extension supports creating, editing, and displaying quizzes along with basic grading/user feedback. You can also save general stats, like the average user score on a quiz and the number of submissions.
Individual user scores may now be recorded. However, the user must be logged in. Currently, only the user can view their own results, though I'll add more features regarding this soon. The only way to view a users score at the moment if you're not the user is to check the database tables themselves with PhpMyAdmin or similar.
Extension is in BETA. I cannot officially endorse its use on production sites. If you do use on a live site, be sure to test extensively!
Simply create your questions, add them to quizzes, and post them to your site.
Requirements
To get started, all you need in a Joomla 4 website with a Bootstrap 5 compatible template. Most templates should work.
If you find this extension useful, please consider leaving me a tip or purchasing a subscription to my site. Thanks.
Need Help or Customizations?
Please direct all questions, feedback, and bug reports related to this extension to the Joomla/KG Extension Support Forum. I will try to answer requests in a timely manner.
For priority support with one or two questions, please leave a tip of $10 or more. If you want simple customizations to make this component fit better into your site, please purchase the priority support sponsorship ($60). If you want more advanced customizations, please contact me via the contact form on the bottom of this page.
Question Types
Currently, YAQ supports 3 types of quizzes.
Multiple Choice

The standard type of question. A user selects from one of several predefined options and gets points for selecting the right one.
True/False

Nearly identical to multiple choice, but with only true/false options.
Short Answer

The user types an answer in a textbox. If it matches any of the predefined answers, it is counted as correct.
Global Component Options
You may access the global component options from the "GConfig" option in the toolbar, or through the site global configuration.
First Tab... YAQuiz
The first tab contains a few general settings, like the overall quiz theme (styling - colors, basic layout, and such...)
You can record hits and submission counts. Note if caching is enabled your hitcount will probably be off.
Global Options
These are options that apply to all quizzes. The quiz access level is the default access level for a quiz, it can be overridden at the quiz level.
Randomize Multiple Choice... just shows the multiple choice question responses in random order.
Load MathJax loads MathJax, which is a JavaScript library that renders MathML/LaTeX equations. So if you're doing a lot of math problems you'll probably want to learn how to use this.
Language
Here you can set a few basic language/text display options without having to manually edit or override the language files.
Permissions
The only permissions the component really respects at the moment are delete and edit permissions. If a group is allowed to edit, they can create, modify, save any quiz/question in the extension. If they have delete permission, they can delete any quiz or question.
How To Use - Categories and Questions
Create Categories
Quizzes and questions can be sorted into categories. This is optional. If you only have a few questions and quizzes, you might not need to use categories. If you plan on creating many quizzes, you'll want to use categories to easier filter through your questions when you go to add them to the quizzes, or it may be difficult to find the questions you're looking for.
Categories have no bearing on the quizzes or questions themselves. They're just an organizational tool to help filter your questions and quizzes in the backend.
I created the category system using the default Joomla com_categories - so there are additional fields and options for things like a description, alias, layout, publishing, etc... all these fields have no bearing on YAQuiz. You can ignore them. The only relevant field is the category name itself.
Categories are shared between Quizzes and Questions. So if you create a "Math" category, you could put all your math quizzes and math questions in the same category.
You can create subcategories, but note that filtering only works by current category. The filters are not currently set up to filter through a category and its subcategories. So if you have an "Algebra" category as a subcategory of the "Math" category - you have to go to the "Algebra" category to see the algebra questions, going to the "Math" category won't show the questions or quizzes in the Algebra category, too. They're separate things.

Create Questions
Next, create some questions you want to put in a quiz. You can also create the quiz first if you want and add questions later if you want.
Open the questions manager and use the "New Question" button to create a question.
The question field is the question itself. Basically the title of the question. Try not to make this area too long. If you have a lot of details you want to add, add them to the editor below.
You can add any images, lists, HTML, etc. to the details field. This will be displayed below the question title and above the user response fields.
You need to set the question type. Once you save a question the first time, you cannot change the question type. For example, if you select "true/false" and actually wanted to use a short answer question, you need to delete the old question and make a new one.

Points
Optionally, you can have different point values for different questions. By default, the points system is turned off for quizzes and each question is worth the same amount of points (1). If you want to make harder questions worth more points, this is where you start. If you don't plan on using points, you can ignore this.
Possible Answers
Once a question is saved, you'll be shown fields that allow you to add/edit the correct answers for the question.
For multiple choice questions, you type all the possible answers, and select the correct one by marking it as correct. The answer option will turn green when you do this. Be sure to save.

For true/false, just select if the correct answer is true or false using the radio buttons.

For short answer questions, you need to decide if the answers are case sensitive. Usually, you probably don't want case sensitivity turned on. Enter all the possible answers you want to count as correct.
For example, if you want the answer to be "New York City" you might enter the possible answers as "new york city" "new york" "newyork city" and "nyc" - if the user types any of these they get full points for the question. If they type anything else, it's counted as wrong. Try to think of what a user might end up typing here - check for knowledge, not for semantics!

General Tips: Be specific with your questions, avoid trick questions, and avoid any ambiguity.
Question Feedback
You can provide individualized feedback for each question. This will be displayed if the "show feedback" option is turned on for the quiz. If you leave these fields blank, it will just say correct or incorrect.
For example, if a user gets a question wrong, you can show feedback explaining why the correct answer was different.
Quiz Manager
Once you've created some questions, you need to create a quiz to hold them all. Click "New Quiz" under the "Quizzes" page to add a new quiz.
Name the quiz and provide a basic description. This description is shown to users before they start the quiz. You can explain what the quiz is about, how many questions it has, and how it's graded here.

There are several other options available for each quiz...
- Display Mode
- Default - Single Page - All questions are shown together on one page.
- Multi Page / Individual Questions - All questions are shown individually, on their own separate pages. Note that this is probably the least performant option, since the user must wait for each page to load when answering each question.
- JavaScript - This is like the multi page quiz, but all the processing is done on the client/user PC with JS rather than by submitting a form and checking it against answers in the database. This option can be fully cached and is probably the fastest, least server intensive option. However, you won't be able to save user results or statistics with this option (once I add those features...)
- All the answers to each question are exposed in the page's source code. So tech savvy users could easily figure out all the answers before submitting the quiz. This is fine for review quizzes, but might make it inappropriate for any professional or institutional use.
- Display quiz feedback
- Allows the user to review all their answers and see what ones they got wrong, along with any custom feedback set at the question level
- Show Correct Answer
- This automatically adds the correct answer(s) if applicable to the feedback page. For example, if the user gets a question wrong, it will tell them what the right option was.
- Number Questions
- Numbers questions starting from 1 and displays this to the user
- Use Points System
- If yes, each question will be worth its point value when correct. If no, each question is worth the same amount - one point.
- Passing Score
- The percentage required to pass the quiz. For example, if set at 70, the user must get 70% of the questions (or points) to pass the quiz.
Adding Questions to Quiz
Once you save a quiz, you can add questions to it from the quiz details page. A tool on this page allows you to filter through the entire question pool and add the questions to your quiz.
Just select the question(s) you want to add from the list and click add questions.
You can reorder questions once they're added to the quiz.
Note, you can add the same question to multiple quizzes if you want. If you change or delete that shared question later, it will be changed across all quizzes it's a part of.
Removing a question from the Quiz on the Quiz Details page does not delete the question entirely, but it does remove it from the quiz.
Display Quiz
You can display the quiz on the front end for users to complete by either copy/pasting the link provided, or by creating a new menu item of type "YAQuiz" and setting the Select Quiz options under the menu item.