Do My Friends Know Me?

How well do your friends know you? Create a custom Quiz Game all about you and your interests! You pick the topic questions and the answers. Give your friends the quiz and see how well they know you.

For an example click here


Directions

  1. Create a web page with a personlized headline such as:

    Do you know Jackie?

    Put a picture of yourself if you'd like.

  2. Add these Page Elements to the page:
    * 2 buttons - one to get the question, one to give the answer
    * 3 labels - one for the question, 1 for the answer, and 1 more for the comment.
    * 1 input area - for the user to give the response
    * 1 img area - to put the image associated with the answer.

    Make sure all the Page Elements have an id="..." field.

    <p id="questionLabel">


  3. Setup an array with 3 or more question on topics you are interested in. Somtheing like:
    "Who is my favorite Hip-Hop recording artist?"
    "What is my favorite museum in New York City?"
    "Who are the best comedians out there?"

  4. When the getQuestion button is clicked, randomly pick one of the available questions and show it to the user in the Question label. Something like:

    document.getElementById("questionLabel").innerHTML = questions[randNum]



  5. When the user clicks the giveAnswer button, take the response, and see if it matches one of your answers. If so, show the answer, the comment and the associated image, like:

    if (response.includes("batman")) {
      SHOW BATMAN STUFF
    }


  6. Build out 4-5 answers for each of the 3 questions. Add more to make guessing more fun.

  7. Add points and count how many chances the user has had.

  8. After the user is out of chances, rate them on how well they know you. Have fun here! :)

  9. Keep working on the project and customizing until you are satisfied. Ask your teacher/TA to upload it to your public folder.





(c) 2017 by Code Craft Academy