//} // end of JS function function getDepts(){ // ON or after selection of category this function will work removeAllOptions(document.getElementById('department')); //addOption(document.getElementById('department'), "", "department", ""); // Collect all element of department for various institutions var select = document.getElementById('department'); select.innerHTML = ""; if(document.getElementById('institution').value == '2'){addOption(document.getElementById('department'),'73', 'DCC');addOption(document.getElementById('department'),'6', 'EDINA');addOption(document.getElementById('department'),'105', 'EPIS');addOption(document.getElementById('department'),'15', 'Institute for Astronomy');addOption(document.getElementById('department'),'1', 'School of GeoSciences');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '7'){addOption(document.getElementById('department'),'153', 'Computing Services');addOption(document.getElementById('department'),'104', 'Department of Zoology');addOption(document.getElementById('department'),'54', 'Young Lives Centre - Department of International Development');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '10'){addOption(document.getElementById('department'),'37', 'Data Protection Office');addOption(document.getElementById('department'),'44', 'DCS');addOption(document.getElementById('department'),'42', 'Department of Theatre Film and TV Studies (TFTS)');addOption(document.getElementById('department'),'46', 'GUARD');addOption(document.getElementById('department'),'13', 'HATII');addOption(document.getElementById('department'),'57', 'Olympic success research project');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '18'){addOption(document.getElementById('department'),'118', 'Academic Services');addOption(document.getElementById('department'),'45', 'Centre for Computing in the Humanities');addOption(document.getElementById('department'),'19', 'Centre for e-Research');addOption(document.getElementById('department'),'58', 'Randall Division of Cell & Molecular Biophysics');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '47'){addOption(document.getElementById('department'),'49', 'Biology');addOption(document.getElementById('department'),'50', 'Chemistry');addOption(document.getElementById('department'),'48', 'Libraries');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '51'){addOption(document.getElementById('department'),'137', 'IAM');addOption(document.getElementById('department'),'52', 'Library');addOption(document.getElementById('department'),'53', 'School of Social Sciences');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '55'){addOption(document.getElementById('department'),'56', 'NSW Office');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '59'){addOption(document.getElementById('department'),'60', 'Admin');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '61'){addOption(document.getElementById('department'),'62', 'Digital Library Systems and Services');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '63'){addOption(document.getElementById('department'),'64', 'Digital Initiatives & IT');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '65'){addOption(document.getElementById('department'),'66', 'Language Centre');addOption(document.getElementById('department'),'195', 'London Deanery');addOption(document.getElementById('department'),'184', 'Wolfson Institute of Biomedical Research');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '67'){addOption(document.getElementById('department'),'68', 'ICPSR');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '69'){addOption(document.getElementById('department'),'70', 'School of Archaeology');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '71'){addOption(document.getElementById('department'),'72', 'Information Technology Services');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '74'){addOption(document.getElementById('department'),'75', 'IT Services');addOption(document.getElementById('department'),'115', 'School of Social Sciences');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '76'){addOption(document.getElementById('department'),'77', 'IT');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '78'){addOption(document.getElementById('department'),'213', 'Government');addOption(document.getElementById('department'),'141', 'Library');addOption(document.getElementById('department'),'79', 'UKRDS');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '80'){addOption(document.getElementById('department'),'81', 'Health');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '82'){addOption(document.getElementById('department'),'83', 'University Libraries');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '84'){addOption(document.getElementById('department'),'144', 'Carolina Digital Library and Archive');addOption(document.getElementById('department'),'85', 'Health Sciences Library');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '86'){addOption(document.getElementById('department'),'87', 'ISS');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '88'){addOption(document.getElementById('department'),'89', 'School of Ocean Sciences');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '90'){addOption(document.getElementById('department'),'91', 'Department of Information Science');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '92'){addOption(document.getElementById('department'),'93', 'Academic Services');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '94'){addOption(document.getElementById('department'),'95', 'School of Engineering, Design and Technology');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '96'){addOption(document.getElementById('department'),'97', 'Social Science Data Archive');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '98'){addOption(document.getElementById('department'),'99', 'Library');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '100'){addOption(document.getElementById('department'),'101', 'UK Data Archive');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '102'){addOption(document.getElementById('department'),'103', 'Faculty of Medicine');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '106'){addOption(document.getElementById('department'),'107', 'Mechanical Engineering');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '108'){addOption(document.getElementById('department'),'109', 'Digital Preservation');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '110'){addOption(document.getElementById('department'),'112', 'Crop and Soil');addOption(document.getElementById('department'),'111', 'DISCOVER');addOption(document.getElementById('department'),'133', 'Ornithology');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '113'){addOption(document.getElementById('department'),'136', 'Astronomy');addOption(document.getElementById('department'),'114', 'Brown Science & Engineering Library');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '116'){addOption(document.getElementById('department'),'117', 'Research Management');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '119'){addOption(document.getElementById('department'),'120', 'Economics and International Business');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '121'){addOption(document.getElementById('department'),'122', 'Global Security & Crisis management Unit');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '123'){addOption(document.getElementById('department'),'124', 'College Archives & Corporate Records Unit');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '125'){addOption(document.getElementById('department'),'126', 'The Operations Centre (Computing and Information Services)');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '127'){addOption(document.getElementById('department'),'128', 'Management');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '129'){addOption(document.getElementById('department'),'130', 'H.G. Thode Library of Science and Engieering');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '131'){addOption(document.getElementById('department'),'132', 'Digital Library Center');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '134'){addOption(document.getElementById('department'),'135', 'Data Auditing Dept.');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '138'){addOption(document.getElementById('department'),'139', 'Cardiff Research Centre');addOption(document.getElementById('department'),'140', 'CYPP');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '142'){addOption(document.getElementById('department'),'143', 'Computing');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '146'){addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '147'){addOption(document.getElementById('department'),'148', 'Library');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '149'){addOption(document.getElementById('department'),'150', 'Chief Executives');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '151'){addOption(document.getElementById('department'),'152', 'Architecture & Design');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '154'){addOption(document.getElementById('department'),'155', 'Office of Information Technology');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '156'){addOption(document.getElementById('department'),'157', 'Mechanical Engineering');addOption(document.getElementById('department'),'170', 'UKOLN');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '158'){addOption(document.getElementById('department'),'159', 'Default');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '160'){addOption(document.getElementById('department'),'161', 'CCSIE');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '162'){addOption(document.getElementById('department'),'163', 'DAT');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '164'){addOption(document.getElementById('department'),'165', 'Children, Schools and Families');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '166'){addOption(document.getElementById('department'),'167', 'IT Services');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '168'){addOption(document.getElementById('department'),'169', 'Library and Learning Resources Centre');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '172'){addOption(document.getElementById('department'),'173', 'Department of Psychology');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '174'){addOption(document.getElementById('department'),'175', 'Strategic Management');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '176'){addOption(document.getElementById('department'),'177', 'SSC');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '178'){addOption(document.getElementById('department'),'179', 'Intelligent Addressing');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '180'){addOption(document.getElementById('department'),'181', 'School of Library and Information Science');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '182'){addOption(document.getElementById('department'),'183', 'Information Services');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '185'){addOption(document.getElementById('department'),'186', 'Environmental Information Data Centre');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '187'){addOption(document.getElementById('department'),'188', 'Faculty of Library and Information Science');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '189'){addOption(document.getElementById('department'),'190', 'School of Electronics and Computer Science');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '191'){addOption(document.getElementById('department'),'192', 'Information Systems');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '193'){addOption(document.getElementById('department'),'194', 'RCLT');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '196'){addOption(document.getElementById('department'),'197', 'Library');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '198'){addOption(document.getElementById('department'),'199', 'ScotCen');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '200'){addOption(document.getElementById('department'),'201', 'Information Technology');addOption(document.getElementById('department'),'208', 'Psychology');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '202'){addOption(document.getElementById('department'),'203', 'Default');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '204'){addOption(document.getElementById('department'),'205', 'TACC');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '206'){addOption(document.getElementById('department'),'207', 'Records & Archives');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '209'){addOption(document.getElementById('department'),'210', 'Hull University Archives');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '211'){addOption(document.getElementById('department'),'212', 'Library');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '214'){addOption(document.getElementById('department'),'215', 'Health Science Center Libraries');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '217'){addOption(document.getElementById('department'),'218', 'Department of Information Sciences');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '219'){addOption(document.getElementById('department'),'220', 'Health Solutions');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '221'){addOption(document.getElementById('department'),'223', 'All');addOption(document.getElementById('department'),'222', 'Emergency Support');addOption(document.getElementById('department'), '_other', 'Other...');}if(document.getElementById('institution').value == '224'){addOption(document.getElementById('department'),'225', 'Default');addOption(document.getElementById('department'), '_other', 'Other...');} } ////////////////// function removeAllOptions(selectbox) { var i; for(i=selectbox.options.length-1;i>=0;i--) { //selectbox.options.remove(i); selectbox.remove(i); } } function addOption(selectbox, value, text ) { var optn = document.createElement("option"); optn.text = text; optn.value = value; selectbox.options.add(optn); }