Creating a quiz and I want to load a js file based on the selection from a dropdown box, so far I have the following to assign the class as the category-name:
<div>
<label for="test">Select test:</label>
<select id="test" class="category-name" name="test">
<option value="a.js">A</option>
<option value="b.js">B</option>
<option value="c.js">C</option>
</select>
</div>
<button type="button" class="btn btn-primary lift" onclick="loadQuestionsForCategory()">Load Questions</button>
</section>
<script src='assets/resources/questions.js'></script>
Instead of loading questions.js, how would I load a.js or b.js depending on the option that's selected?