shortlist-digital/wp-quiz-post-plugin

A plugin for our own quiz posts

Installs: 2 127

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 3

Forks: 0

Open Issues: 0

Type:wordpress-plugin

2.0.1 2019-01-02 12:24 UTC

This package is not auto-updated.

Last update: 2019-08-30 13:42:58 UTC


README

A plugin for our own quiz posts

Sample JSON

"acf": {
    "short_headline": "Can you do this quiz?",
    "sell": "It's REALLY hard...",
    "category": {},
    "tags": false,
    "hero_images": [],
    "standfirst": "",
    "header_type": "hero",
    "header_display_date": true,
    "sponsored": true,
    "sponsor_name": "Cadbury Freddo",
    "sponsor_logo": false,
    "sponsor_link": "",
    "sponsor_type": "advance",
    "sponsor_label": "powered-by",
    "disable_advert_slots": "",
    "introduction_text": "<p>This quiz is SO hard! It’s probably based on some twitter thread that’s currently trending, probably about primary school maths that no one can remember so everyone is slightly outraged that kids are expected to do it. Or some blue/gold dress that everyone’s arguing about.</p>\n",
    "questions": [
        {
            "question_text": "This is the first text based question?",
            "question_image": false,
            "correct_answer_text": "Yes",
            "correct_answer_image": false,
            "incorrect_answers": [
                {
                    "incorrect_answer_text": "Maybe",
                    "incorrrect_answer_image": false
                },
                {
                    "incorrect_answer_text": "No",
                    "incorrrect_answer_image": false
                }
            ],
            "answer_reveal_text": "Wow this was an easy question to start off with!",
            "answer_reveal_image": false
        },
        {
            "question_text": "What colour do you see looking at this dress?",
            "question_image": {
                "ID": 11,
                "id": 11,
                "title": "Can you guess all these questions?",
                "filename": "ricky-kharawala-10194-7.jpg",
                "url": "https://shortlist.com/wp-content/uploads/2018/01/ricky-kharawala-10194-7.jpg",
                "alt": "Can you guess all these questions?",
                "author": "0",
                "description": "",
                "caption": "",
                "name": "ricky-kharawala-10194",
                "date": "2018-01-24 15:28:15",
                "modified": "2018-02-14 12:18:53",
                "mime_type": "image/jpeg",
                "type": "image",
                "icon": "https://shortlist.com/wp-includes/images/media/default.png",
                "width": 2048,
                "height": 1357,
                "sizes": {}
            },
            "correct_answer_text": "Black and blue",
            "correct_answer_image": {
                "ID": 10,
                "id": 10,
                "title": "Can you guess all these questions? 1",
                "filename": "pikachuuu-7.png",
                "url": "https://shortlist.com/wp-content/uploads/2018/01/pikachuuu-7.png",
                "alt": "Can you guess all these questions? 1",
                "author": "0",
                "description": "",
                "caption": "",
                "name": "pikachuuu",
                "date": "2018-01-24 15:28:13",
                "modified": "2018-02-14 12:18:54",
                "mime_type": "image/png",
                "type": "image",
                "icon": "https://shortlist.com/wp-includes/images/media/default.png",
                "width": 1254,
                "height": 1254,
                "sizes": {}
            },
            "incorrect_answers": [
                {
                    "incorrect_answer_text": "#whiteandgold",
                    "incorrrect_answer_image": {
                        "ID": 9,
                        "id": 9,
                        "title": "Can you guess all these questions? 2",
                        "filename": "luca-ambrosi-421156-7.jpg",
                        "url": "https://shortlist.com/wp-content/uploads/2018/01/luca-ambrosi-421156-7.jpg",
                        "alt": "Can you guess all these questions? 2",
                        "author": "0",
                        "description": "",
                        "caption": "",
                        "name": "luca-ambrosi-421156",
                        "date": "2018-01-24 15:28:11",
                        "modified": "2018-02-14 12:18:54",
                        "mime_type": "image/jpeg",
                        "type": "image",
                        "icon": "https://shortlist.com/wp-includes/images/media/default.png",
                        "width": 2048,
                        "height": 1356,
                        "sizes": {}
                    }
                }
            ],
            "answer_reveal_text": "Eyes are weird.",
            "answer_reveal_image": {
                "ID": 7,
                "id": 7,
                "title": "Can you guess all these questions? 3",
                "filename": "jairo-alzate-45522-7.jpg",
                "url": "https://shortlist.com/wp-content/uploads/2018/01/jairo-alzate-45522-7.jpg",
                "alt": "Can you guess all these questions? 3",
                "author": "0",
                "description": "",
                "caption": "",
                "name": "jairo-alzate-45522",
                "date": "2018-01-24 15:28:06",
                "modified": "2018-02-14 12:18:54",
                "mime_type": "image/jpeg",
                "type": "image",
                "icon": "https://shortlist.com/wp-includes/images/media/default.png",
                "width": 2048,
                "height": 1371,
                "sizes": {}
            }
        }
    ],
    "quiz_type": true,
    "bad_score_text": "You really suck at this…",
    "bad_score_image": {
        "ID": 6,
        "id": 6,
        "title": "Can you guess all these questions? 4",
        "filename": "dominik-lange-41372-7.jpg",
        "url": "https://shortlist.com/wp-content/uploads/2018/01/dominik-lange-41372-7.jpg",
        "alt": "Can you guess all these questions? 4",
        "author": "0",
        "description": "",
        "caption": "",
        "name": "dominik-lange-41372",
        "date": "2018-01-24 15:28:05",
        "modified": "2018-02-14 12:18:55",
        "mime_type": "image/jpeg",
        "type": "image",
        "icon": "https://shortlist.com/wp-includes/images/media/default.png",
        "width": 1361,
        "height": 2048,
        "sizes": {}
    },
    "average_score_text": "Meh, you’re average.",
    "average_score_image": {
        "ID": 5,
        "id": 5,
        "title": "Can you guess all these questions? 5",
        "filename": "big-hero-image-7.jpg",
        "url": "https://shortlist.com/wp-content/uploads/2018/01/big-hero-image-7.jpg",
        "alt": "Can you guess all these questions? 5",
        "author": "0",
        "description": "",
        "caption": "",
        "name": "big-hero-image",
        "date": "2018-01-24 15:28:03",
        "modified": "2018-02-14 12:18:55",
        "mime_type": "image/jpeg",
        "type": "image",
        "icon": "https://shortlist.com/wp-includes/images/media/default.png",
        "width": 1680,
        "height": 880,
        "sizes": {}
    },
    "good_score_text": "PERFECT SCORE!!!",
    "good_score_image": {
        "ID": 4,
        "id": 4,
        "title": "Can you guess all these questions? 6",
        "filename": "600x450-7.png",
        "url": "https://shortlist.com/wp-content/uploads/2018/01/600x450-7.png",
        "alt": "Can you guess all these questions? 6",
        "author": "0",
        "description": "",
        "caption": "",
        "name": "600x450",
        "date": "2018-01-24 15:28:02",
        "modified": "2018-02-14 12:18:55",
        "mime_type": "image/png",
        "type": "image",
        "icon": "https://shortlist.com/wp-includes/images/media/default.png",
        "width": 600,
        "height": 450,
        "sizes": {}
    },
    "quiz_conclusion": "<p>So, now that you’ve done this and you’re hooked, try some more of our GREAT QUIZZES!</p>\n",
    "share_title": "",
    "share_description": "",
    "share_image": false,
    "twitter_text": "",
    "related_show": true,
    "related_limit": "6",
    "related_lists": false,
    "related_manual_posts": false
}

Alternate ending

...
    "quiz_type": false,
    "quiz_conclusion": "<p>asdf</p>\n",
...