A couple of years ago I was asked by our languages coordinator to ‘digitise’ some diagnostic language tests for students to assess their level of language knowledge prior to enrolment.
The basic remit of the task was that students should take a test and, depending on their score, be directed to enrol on a course designed for their target language level. Scores did not need to be stored for future access, and no student data needed to be collected.
I was provided with word documents consisting of tests for 5 languages; each test was divided into 5 sections of 10 questions; the questions were all three-item multiple choice (MCQs) with one correct answer; the 5 sections increased in order of difficulty, corresponding roughly to CEFR levels A1, A2, B1, B2, C1.
The basic parameters were: if a student scored less than 5/10 on a level, then they would be directed to the enrolment page for their designated level. If they scored 5/10 or above, they would be directed to the next level, thereby progressing.
I decided to use PHP to accomplish this. PHP stands for ‘PHP Hypertext Preprocessor (a recursive acronym); it’s a server-side scripting language, and is relatively easy to write.
The coding consists of a page of questions for each section. The questions are stored in an array, which is then called through a foreach loop structure to output the 10 questions to HTML radio button form fields; a submit button calls a post method to a php file containing the correct answers stored in arrays for each level. The arrays are parsed and checked against the submitted answers using loops, if and switch control structures to calculate the result and then output a response to the HTML page, informing the student of their score and directing to either the enrolment page or the next page of the test.
Thus, a very simple form of computer-adaptive test was created for 5 different languages. You can try them yourself here: