// This function is called when any of the tab is clicked // It is adapted from https://www.w3schools.com/howto/howto_js_tabs.asp function openInfo(evt, tabName) { // Get all elements with class="tabcontent" and hide them tabcontent = document.getElementsByClassName("tabcontent"); for (i = 0; i < tabcontent.length; i++) { tabcontent[i].style.display = "none"; } // Get all elements with class="tablinks" and remove the class "active" tablinks = document.getElementsByClassName("tablinks"); for (i = 0; i < tablinks.length; i++) { tablinks[i].className = tablinks[i].className.replace(" active", ""); } // Show the current tab, and add an "active" class to the button that opened the tab document.getElementById(tabName).style.display = "block"; evt.currentTarget.className += " active"; } // generate a checkbox list from a list of products // it makes each product name as the label for the checkbos function populateListProductChoices(slct1, slct2) { var s1 = document.getElementById(slct1); var s2 = document.getElementById(slct2); // s2 represents the