Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.


  1. A view class and template in [customization_folder]/views/question_customtype/view.html.php and [customization_folder]/views/question_customtype/tmpl/default.php

  2. CSS styling in [customization_assets_folder]/css/custom.css

  3. A JS question type object in [customization_assets_folder]/javascript/custom_questions.js

  4. Optionally: Add data fields to question data

View Class and Template

The class and template is responsible for adding the HTML of any question of this type to the configurator page. Question data and the current selection of the user is available to the template by default. See View class and template for details.


While the user interacts on a configurator page, the CB framework triggers JavaScript events and each question type reacts on these events (e.g. changes to the current user selection, activation or deactivation of a question, displaying a validation message etc). To make your question type react, you create a JS Question Type Object that contains callback functions and register it using a framework function. See the full details in JS question type object.

Add data fields to question data

You may need specific fields in backend edit screens to support your question type. Learn here how to add properties to question data.