/** * Advanced Taxonomy Reengineering - SJB Final Interceptor * Reconstructs dropdowns into organized hierarchies. */ (function() { const reengineerCategories = () => { // Target the category select by name to ignore dynamic IDs const selectNodes = document.querySelectorAll('select[name="categories[]"]'); selectNodes.forEach(selectElement => { // Prevent duplicate processing if (selectElement.dataset.reengineered === 'true') return; const $select = window.jQuery ? jQuery(selectElement) : null; // 1. Force-destroy the existing SJB Multiselect widget to allow DOM changes if ($select && $select.data("ech-multiselect")) { $select.multiselect('destroy'); } const optionsArray = Array.from(selectElement.options); let currentOptGroup = null; optionsArray.forEach(option => { const text = option.text; // 2. Identify and Clean Header Labels if (text.includes('(Do NOT select this one')) { // Extract prefix (e.g., "FACULTY, POSTDOC, DEPARTMENT HEAD") const cleanLabel = text.split(':')[0].trim(); currentOptGroup = document.createElement('optgroup'); currentOptGroup.label = cleanLabel; selectElement.insertBefore(currentOptGroup, option); option.remove(); } // 3. Purge legacy separator lines else if (text.includes('---')) { option.remove(); } // 4. Group valid options under the current header else if (currentOptGroup && option.value !== "") { currentOptGroup.appendChild(option); } }); selectElement.dataset.reengineered = 'true'; // 5. Re-initialize the SJB widget to render the new hierarchy if ($select) { $select.multiselect({ selectedText: "# selected", noneSelectedText: "Categories", header: false, menuHeight: 'auto', buttonWidth: 'auto' }); } }); }; // Tactical Delay: SJB initializes its scripts at the very end of the . // We wait 200ms after load to ensure our code runs LAST. window.addEventListener('load', () => { setTimeout(reengineerCategories, 200); // Watch for dynamic form injections (modals, AJAX loads) const observer = new MutationObserver(() => reengineerCategories()); observer.observe(document.body, { childList: true, subtree: true }); }); })(); Unlimited Posting Plan Advanced Search Job Alerts Featured Jobs Post a Job Pricing/Plans Post a Resume Sign in Sign up Unlimited Posting Plan Advanced Search Job Alerts Featured Jobs Post a Job Pricing/Plans Post a Resume Keywords Location Find Jobs Find Jobs 0 advising counseling support jobs found in Harrisonburg, VA Refine Search Keywords Location Find Jobs Find Jobs Current Search Other Administrative Positions Harrisonburg, VA advising counseling support Search within 50 miles 10 miles 20 miles 50 miles 100 miles 200 miles Refine by Job Categories Advising/Counseling/Support (1) Email me jobs like this Sorry, we don't currently have any jobs for this search. Please try another search. Load more