Project Description

Assessment Plugin – I created this WordPress plugin to assist a company with their website user assessment needs which are as follows:

  • Requires an Individual Assessment and a Program Assessment page with 7 categories and 5 – 12 questions in each category on each page.
  • User rates each question by choosing one number from 0 – 4, and upon completion cicks Submit button, which displays average scores per category, formatted and styled with text at the bottom of the page

I wrote a javascript in app.js file to loop through lists, and radio buttons in nested lists, building arrays containing average scores per category. I wrote functions to collectAnswers, calculateAverages, add click events to button, and two functions to output concatenated HTML, text and array variable values.

I created two php templates, page-individual-assessment.php and page-program-assessment.php that are loaded into child theme file, and are called when user accesses Individual Assessment and Program Assessment pages. These two php files contain the HTML, list and radio button elements, php template tags and text.

I wrote some basic CSS styling in style.css in the plugin, and in the main plugin file, assess.php, and wrote a function to properly load the js file and stylesheet in WordPress by enqueueing the app.js and style.css files.

This plugin collects user assessment scores for Standard categories in page-individual-assessment.php and page-program-assessment.php files, then displays score results averages to two decimals in each Standard category at bottom of Individual Assessment and Program Assessment pages.