-
First create a database in mySQL database
CREATE DATABASE djangoquiz
-
Open terminal where
manage.py
file is located and run these commands in terminalpython manage.py makemigrations
python manage.py migrate
this will create tables in the database .
-
Now run
python manage.py runserver
-
On server's homepage it'll show
No Quiz Available !!
, that's because no data inserted indjangoquiz
table. -
So Insert data in
djangoquiz
table like Question, Option1, Option2, Option3, Option4 and a Corrans i.e Correct Answer. -
To insert data consider following mySQL query
INSERT INTO 'quiz_exam'('id', 'Question', 'Option1', 'Option2', 'Option3', 'Option4', 'Answer') VALUES ('[value-1]','[value-2]','[value-3]','[value-4]','[value-5]','[value-6]','[value-7]')
-
Then on server homepage questions with their options will appear.
-
Notifications
You must be signed in to change notification settings - Fork 0
Public quiz application
License
prateiku/DjangoQuiz
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
Public quiz application
Topics
Resources
License
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published