May 26, 2020
Trivia game project
Comments
(7)
May 26, 2020
Trivia game project
Master 12 posts
Followers: 8 people
(7)

Preview | Download

This project uses the Open Trivia Database API (https://opentdb.com/) to fetch the questions using the AJAX technology. Once the questions are fetched, the Common JavaScript interface for Adobe Captivate is used to populate the value of Captivate variables that are then used to display the fetched questions to the user. Some basic error handling is also baked into the project if the remote API does not send the expected response. Variables and advanced actions are used to power the Captivate side of this project.

This project demonstrates how to use the AJAX capabilities of the browser to fetch remote data and to use this data to create a game in Adobe Captivate.

Download JS file

See all projects –> 

7 Comments
2020-06-09 22:40:11
2020-06-09 22:40:11

Any advice on what I can reference to learn how to put in the API links to fetch the questions ?

Like
(1)
>
Corey Mclaurin
's comment
2020-06-10 12:08:27
2020-06-10 12:08:27
>
Corey Mclaurin
's comment

See the API documentation at https://opentdb.com/api_config.php

Like
2020-06-09 16:48:45
2020-06-09 16:48:45

I am so lost on how to tell it what questions to pull. Can anyone give me some guidance ?

Like
(1)
>
Corey Mclaurin
's comment
2020-06-10 12:07:58
2020-06-10 12:07:58
>
Corey Mclaurin
's comment

You can choose the topic, and the difficulty of the questions to pull at the beginning of the project, but you cannot tel it to pull specific questions.  It is a limitation of the API we pull questions from. It does not allow to say something like “Pull only question X, Y Z” or “Pull only the questions that I have submitted”.

You can find the API documentation at the following location : https://opentdb.com/api_config.php

I you want to create a similar example with just your questions or just questions on a specific topic, you have 2 solutions

  1. Find another API that let you choose the questions you want
  2. Write your own API

I hope it helps clarifying the way the project works. If not, don’t hesitate to let me know, I’ll be happy to pursue the conversation.

Happy Captivating!

Damien

Like
2020-06-03 19:25:41
2020-06-03 19:25:41

This is a great resource for teachers!

Like
(1)
(2)
>
Layli
's comment
2020-06-04 09:25:34
2020-06-04 09:25:34
>
Layli
's comment

Cool! Glad you like it!

Happy Captivating!

Like
(1)
>
Layli
's comment
2020-06-09 16:58:32
2020-06-09 16:58:32
>
Layli
's comment

Can’t quite figure out how to make Adobe fetch the questions, any tips ?

Like
Add Comment