function fillCategory(){ // this function is used to fill the category list on load addOption(document.frm_item.categoryId, '3', 'Addictions', '0');addOption(document.frm_item.categoryId, '2', 'ADHD/ADD', '0');addOption(document.frm_item.categoryId, '157', 'Adoption/Foster Care', '0');addOption(document.frm_item.categoryId, '132', 'Anger Management', '0');addOption(document.frm_item.categoryId, '129', 'Anxiety/Panic/OCD', '0');addOption(document.frm_item.categoryId, '117', 'Art and Play Therapy', '0');addOption(document.frm_item.categoryId, '130', 'Attachment', '0');addOption(document.frm_item.categoryId, '10', 'Autism/Neurodiversity', '0');addOption(document.frm_item.categoryId, '113', 'Behavior Intervention', '0');addOption(document.frm_item.categoryId, '11', 'Brain Science', '0');addOption(document.frm_item.categoryId, '134', 'Communication Skills', '0');addOption(document.frm_item.categoryId, '131', 'Depression', '0');addOption(document.frm_item.categoryId, '135', 'Early Childhood Education', '0');addOption(document.frm_item.categoryId, '136', 'Eating Disorders', '0');addOption(document.frm_item.categoryId, '116', 'Education/Classroom', '0');addOption(document.frm_item.categoryId, '152', 'EMDR/Energy Medicine', '0');addOption(document.frm_item.categoryId, '138', 'Executive Function', '0');addOption(document.frm_item.categoryId, '34', 'FASD', '0');addOption(document.frm_item.categoryId, '139', 'Grief/Loss', '0');addOption(document.frm_item.categoryId, '153', 'Hawthorne', '0');addOption(document.frm_item.categoryId, '163', 'Health/Wellness/Illness', '0');addOption(document.frm_item.categoryId, '25', 'Inclusion/Disability', '0');addOption(document.frm_item.categoryId, '35', 'Indigenous Resources', '0');addOption(document.frm_item.categoryId, '158', 'LGBTQIA+', '0');addOption(document.frm_item.categoryId, '20', 'Life Skills/Social Skills', '0');addOption(document.frm_item.categoryId, '140', 'Mental Illness', '0');addOption(document.frm_item.categoryId, '122', 'Mindfulness/Mind-Body', '0');addOption(document.frm_item.categoryId, '48', 'Parenting', '0');addOption(document.frm_item.categoryId, '151', 'Personal Growth/Self Help', '0');addOption(document.frm_item.categoryId, '141', 'Personality Disorder', '0');addOption(document.frm_item.categoryId, '92', 'Psychiatry/Psychology', '0');addOption(document.frm_item.categoryId, '115', 'Relationships', '0');addOption(document.frm_item.categoryId, '142', 'Self Esteem', '0');addOption(document.frm_item.categoryId, '143', 'Self-Regulation', '0');addOption(document.frm_item.categoryId, '121', 'Sensory Processing Therapy', '0');addOption(document.frm_item.categoryId, '57', 'Sex Education/Sexuality', '0');addOption(document.frm_item.categoryId, '127', 'Social Thinking™', '0');addOption(document.frm_item.categoryId, '145', 'Time Management', '0');addOption(document.frm_item.categoryId, '68', 'Trauma/PTSD', '0'); } // end of JS function function SelectSubCat(){ // ON or after selection of category this function will work removeAllOptions(document.frm_item.subCategoryId); addOption(document.frm_item.subCategoryId, '', 'No Subcategory Selected', '1');if(document.frm_item.categoryId.value == '2'){addOption(document.frm_item.subCategoryId,'332', 'Adult','0');addOption(document.frm_item.subCategoryId,'418', 'Children','0');addOption(document.frm_item.subCategoryId,'419', 'Pre-Teen/Teen','0');addOption(document.frm_item.subCategoryId,'222', 'Professional/Educator/Parent','0');}if(document.frm_item.categoryId.value == '113'){addOption(document.frm_item.subCategoryId,'191', 'Conduct Disorder/ODD','0');addOption(document.frm_item.subCategoryId,'272', 'Professional/Educator/Assessment','0');}if(document.frm_item.categoryId.value == '129'){addOption(document.frm_item.subCategoryId,'334', 'Adult','0');addOption(document.frm_item.subCategoryId,'420', 'Children','0');addOption(document.frm_item.subCategoryId,'421', 'Pre-Teen/Teen','0');addOption(document.frm_item.subCategoryId,'339', 'Professional/Educator/Parent','0');}if(document.frm_item.categoryId.value == '20'){addOption(document.frm_item.subCategoryId,'226', 'Adults/Parents','0');addOption(document.frm_item.subCategoryId,'227', 'Children and Adolescents','0');addOption(document.frm_item.subCategoryId,'228', 'Professional/Educator','0');}if(document.frm_item.categoryId.value == '48'){addOption(document.frm_item.subCategoryId,'364', 'All Ages','0');addOption(document.frm_item.subCategoryId,'58', 'Behavior','0');addOption(document.frm_item.subCategoryId,'388', 'Children','0');addOption(document.frm_item.subCategoryId,'61', 'Pre-Teens and Teenagers','0');}if(document.frm_item.categoryId.value == '25'){addOption(document.frm_item.subCategoryId,'230', 'Professional/Educator/Parent','0');}if(document.frm_item.categoryId.value == '92'){addOption(document.frm_item.subCategoryId,'86', 'Professional/Reference','0');addOption(document.frm_item.subCategoryId,'256', 'Techniques/Resources','0');}if(document.frm_item.categoryId.value == '68'){addOption(document.frm_item.subCategoryId,'391', 'Adult ','0');addOption(document.frm_item.subCategoryId,'404', 'Child & Adolescent','0');addOption(document.frm_item.subCategoryId,'97', 'Domestic Violence/Abuse/Rape','0');addOption(document.frm_item.subCategoryId,'390', 'Professional/Educator/Parent','0');addOption(document.frm_item.subCategoryId,'325', 'PTSD','0');}if(document.frm_item.categoryId.value == '10'){addOption(document.frm_item.subCategoryId,'411', 'Adult','0');addOption(document.frm_item.subCategoryId,'422', 'Children','0');addOption(document.frm_item.subCategoryId,'269', 'Nonverbal Learning Disabilities','0');addOption(document.frm_item.subCategoryId,'225', 'Pre-Teen/Teen','0');addOption(document.frm_item.subCategoryId,'271', 'Professional/Educator/Parent','0');}if(document.frm_item.categoryId.value == '35'){addOption(document.frm_item.subCategoryId,'279', 'Parents and Educators','0');addOption(document.frm_item.subCategoryId,'288', 'Professional/Educator','0');addOption(document.frm_item.subCategoryId,'194', 'Restorative Justice','0');}if(document.frm_item.categoryId.value == '3'){addOption(document.frm_item.subCategoryId,'232', 'Alcohol/Substance Abuse','0');addOption(document.frm_item.subCategoryId,'188', 'Co-occurring/Dual Diagnosis','0');}if(document.frm_item.categoryId.value == '117'){addOption(document.frm_item.subCategoryId,'340', 'Art Therapy','0');addOption(document.frm_item.subCategoryId,'342', 'Play Therapy','0');addOption(document.frm_item.subCategoryId,'433', 'Play Therapy - All Ages','0');addOption(document.frm_item.subCategoryId,'432', 'Play Therapy - Child/Teen','0');}if(document.frm_item.categoryId.value == '116'){addOption(document.frm_item.subCategoryId,'435', '(SEL) Social & Emotional Learning K-7','0');addOption(document.frm_item.subCategoryId,'436', '(SEL) Social/Emotional Learning 7-12','0');addOption(document.frm_item.subCategoryId,'406', 'Bullying','0');addOption(document.frm_item.subCategoryId,'427', 'Children\'s Lessons','0');addOption(document.frm_item.subCategoryId,'344', 'Grades 7 to 12','0');addOption(document.frm_item.subCategoryId,'343', 'Kindergarten - Gr. 12','0');addOption(document.frm_item.subCategoryId,'246', 'Kindergarten - Gr. 7','0');}if(document.frm_item.categoryId.value == '57'){addOption(document.frm_item.subCategoryId,'263', 'Adults','0');addOption(document.frm_item.subCategoryId,'261', 'Children','0');addOption(document.frm_item.subCategoryId,'262', 'Pre-teens and Adolescents','0');addOption(document.frm_item.subCategoryId,'389', 'Professional/Educator/Parent','0');addOption(document.frm_item.subCategoryId,'405', 'Sex Addiction','0');}if(document.frm_item.categoryId.value == '34'){addOption(document.frm_item.subCategoryId,'354', 'Child/Teen/Parent','0');addOption(document.frm_item.subCategoryId,'249', 'Professional/Educator/Parent','0');}if(document.frm_item.categoryId.value == '115'){addOption(document.frm_item.subCategoryId,'257', 'Communication/Couples','0');addOption(document.frm_item.subCategoryId,'259', 'Conflict/Physical/Emotional Abuse','0');addOption(document.frm_item.subCategoryId,'362', 'Couples/Couples Therapy','0');addOption(document.frm_item.subCategoryId,'412', 'Divorce/Blended Families','0');}if(document.frm_item.categoryId.value == '121'){addOption(document.frm_item.subCategoryId,'283', 'Fine Motor','0');addOption(document.frm_item.subCategoryId,'282', 'Gross Motor','0');addOption(document.frm_item.subCategoryId,'281', 'Oral Motor','0');addOption(document.frm_item.subCategoryId,'285', 'Sensory Processing Books & DVDS','0');addOption(document.frm_item.subCategoryId,'280', 'Sensory Solutions','0');}if(document.frm_item.categoryId.value == '122'){addOption(document.frm_item.subCategoryId,'292', 'Meditation/Stress Reduction','0');addOption(document.frm_item.subCategoryId,'319', 'Mind-body','0');}if(document.frm_item.categoryId.value == '132'){addOption(document.frm_item.subCategoryId,'335', 'Adult','0');addOption(document.frm_item.subCategoryId,'336', 'Child & Adolescent','0');}if(document.frm_item.categoryId.value == '134'){addOption(document.frm_item.subCategoryId,'348', 'Assertiveness','0');addOption(document.frm_item.subCategoryId,'349', 'Boundaries','0');addOption(document.frm_item.subCategoryId,'379', 'Conflict Resolution','0');}if(document.frm_item.categoryId.value == '135'){addOption(document.frm_item.subCategoryId,'434', '(SEL) Social & Emotional Learning','0');addOption(document.frm_item.subCategoryId,'360', 'Parents & Children','0');addOption(document.frm_item.subCategoryId,'361', 'Professional/Educator','0');}if(document.frm_item.categoryId.value == '152'){addOption(document.frm_item.subCategoryId,'351', 'EMDR','0');addOption(document.frm_item.subCategoryId,'416', 'EMDR/ Trauma','0');addOption(document.frm_item.subCategoryId,'381', 'Energy Medicine','0');}if(document.frm_item.categoryId.value == '131'){addOption(document.frm_item.subCategoryId,'352', 'Adult','0');addOption(document.frm_item.subCategoryId,'409', 'Bipolar - Adult','0');addOption(document.frm_item.subCategoryId,'358', 'Child & Adolescent','0');addOption(document.frm_item.subCategoryId,'359', 'Professional/Educator/Parent','0');}if(document.frm_item.categoryId.value == '139'){addOption(document.frm_item.subCategoryId,'424', 'Adult','0');addOption(document.frm_item.subCategoryId,'426', 'Children/Parent','0');addOption(document.frm_item.subCategoryId,'387', 'Pre-Teen/Adolescent','0');addOption(document.frm_item.subCategoryId,'355', 'Professional/Educator/Parent','0');}if(document.frm_item.categoryId.value == '140'){addOption(document.frm_item.subCategoryId,'357', 'Families/Individuals','0');addOption(document.frm_item.subCategoryId,'423', 'Schizophrenia','0');}if(document.frm_item.categoryId.value == '142'){addOption(document.frm_item.subCategoryId,'365', 'Adult','0');addOption(document.frm_item.subCategoryId,'366', 'Child & Adolescent','0');addOption(document.frm_item.subCategoryId,'367', 'Professional/Educator/Parent','0');}if(document.frm_item.categoryId.value == '151'){addOption(document.frm_item.subCategoryId,'369', 'Codependency/Family of Origin','0');}if(document.frm_item.categoryId.value == '136'){addOption(document.frm_item.subCategoryId,'370', 'Child/Adolescent/Adult','0');addOption(document.frm_item.subCategoryId,'372', 'Professional/Educator/Parent','0');}if(document.frm_item.categoryId.value == '11'){addOption(document.frm_item.subCategoryId,'376', 'Adult','0');addOption(document.frm_item.subCategoryId,'377', 'Professional/Educator/Parent','0');}if(document.frm_item.categoryId.value == '141'){addOption(document.frm_item.subCategoryId,'407', 'Borderline','0');addOption(document.frm_item.subCategoryId,'408', 'Narcissism','0');}if(document.frm_item.categoryId.value == '127'){addOption(document.frm_item.subCategoryId,'444', 'Adult','0');addOption(document.frm_item.subCategoryId,'413', 'Autism/Neurodiversity','0');addOption(document.frm_item.subCategoryId,'441', 'Children','0');addOption(document.frm_item.subCategoryId,'442', 'Pre-teen/Teen','0');}if(document.frm_item.categoryId.value == '157'){addOption(document.frm_item.subCategoryId,'415', 'Child & Adolescent','0');addOption(document.frm_item.subCategoryId,'414', 'Parents & Professionals','0');}if(document.frm_item.categoryId.value == '163'){addOption(document.frm_item.subCategoryId,'440', 'All Ages','0');} } ////////////////// 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,selected ) { var optn = document.createElement("OPTION"); optn.text = text; optn.value = value; if (selected==1) { optn.selected = true; } selectbox.options.add(optn); }