'+ '
'+ '

'+splitedAvailableCitiesList[i]+'

'+ '
'+ '
'+ ''; $(".location-mob").append(locationHtml); } } }); }); $(document).ready(function(){ $("#institutions").on("keyup", function (e) { var q = $("#institutions").val(); var city = localStorage.getItem("user_city"); var query = q.replace(/[-+.^:']/g, ""); $.ajax({ type: 'GET', url: "" + window.secureUnsecure + "findSuggestion/" + city + " as " + query, data: "", dataType: "json", success: function (b) { var autoSuggestionData = b; var html = ""; $(".institutions").hide(); $('.bb-auto-mob-suggestive-list table tbody').empty(); if(autoSuggestionData.COLLEGE.length > 0 || autoSuggestionData.SCHOOL.length > 0 || autoSuggestionData.PLAYSCHOOL.length > 0 || autoSuggestionData.COURSE.length > 0 || autoSuggestionData.COACHINGCENTRE.length > 0){ for (var type in autoSuggestionData) { var imageUrl = ""; if(type == 'PLAYSCHOOL'){ imageUrl = "https://storage.googleapis.com/bb-resources/phaseIII/images/latest-student-home/mob-bottom-strip/mobile-pages/search-page/playschool.png"; }else if(type == 'SCHOOL'){ imageUrl = "https://storage.googleapis.com/bb-resources/phaseIII/images/latest-student-home/mob-bottom-strip/mobile-pages/search-page/school.png"; }else if(type == 'COLLEGE'){ imageUrl = "https://storage.googleapis.com/bb-resources/phaseIII/images/latest-student-home/mob-bottom-strip/mobile-pages/search-page/college.png"; }else if(type == 'COACHINGCENTRE'){ imageUrl = "https://storage.googleapis.com/bb-resources/phaseIII/images/latest-student-home/mob-bottom-strip/mobile-pages/search-page/coaching%20center.png"; }else{ imageUrl = "https://storage.googleapis.com/bb-resources/phaseIII/images/latest-student-home/mob-bottom-strip/mobile-pages/search-page/online-course.png"; } if(autoSuggestionData[type].length){ html += ''+ ''+ '

'+type+'

'+ '
'; for (var inst in autoSuggestionData[type]) { var instData = autoSuggestionData[type][inst].replace(/_/g, "-").split("="); var value = instData[0].split(" as "); var cityValue; var instiVal; var localityValue; var instn; var courseVal; var qCourse; if(type != 'COURSE'){ if (city == "India" || city == "Delhi NCR") { instn = instData[2].split("-instituteId-"); //cityValue = instn[0].replace(/ /g, "-"); cityValue = instn[0].replace(/-/g, '_').replace(/ /g, "-"); instiVal = value[1].replace(/ /g, "-"); instiValUrl = instiVal.replace(/\//g, "_"); //localityValue = instData[1].replace(/ /g, "-"); localityValue = instData[1].replace(/-/g, '_').replace(/ /g, "-"); } else { //cityValue = value[0].replace(/ /g, "-"); cityValue = value[0].replace(/-/g, '_').replace(/ /g, "-"); instiVal = value[1].replace(/ /g, "-"); instiValUrl = instiVal.replace(/\//g, "_"); instn = instData[1].split("-instituteId-"); //localityValue = instn[0].replace(/ /g, "-"); localityValue = instn[0].replace(/-/g, '_').replace(/ /g, "-"); } }else{ courseVal = autoSuggestionData[type][inst].replace(/_/g, "-"); qCourse = courseVal.replace(/\+/g, "_"); } var url = ""; var instituteName = ""; if(type == 'PLAYSCHOOL'){ if(autoSuggestionData[type][inst].indexOf("-instituteId-") > -1){ url = window.secureUnsecure + '' + cityValue.toLowerCase() + '/playschoolDetailPage/' + instiValUrl.toLowerCase() + '-in-' + localityValue.toLowerCase() + '?id='+instn[1]; instituteName = instiVal.replace(/-/g, " ") + ', ' + localityValue.replace(/-/g, " ").replace(/_/g, "-") + ', ' + cityValue.replace(/-/g, " ").replace(/_/g, "-"); }else{ url = window.secureUnsecure + '' + cityValue.toLowerCase() + '/playschool/' + instiValUrl.toLowerCase() + '-in-' + localityValue.toLowerCase(); instituteName = instiVal.replace(/-/g, " ") + ', ' + localityValue.replace(/-/g, " ").replace(/_/g, "-") + ', ' + cityValue.replace(/-/g, " ").replace(/_/g, "-"); } }else if(type == 'SCHOOL'){ if(autoSuggestionData[type][inst].indexOf("-instituteId-") > -1){ url = window.secureUnsecure + '' + cityValue.toLowerCase() + '/schoolDetailPage/' + instiValUrl.toLowerCase() + '-in-' + localityValue.toLowerCase() + '?id='+instn[1]; instituteName = instiVal.replace(/-/g, " ") + ', ' + localityValue.replace(/-/g, " ").replace(/_/g, "-") + ', ' + cityValue.replace(/-/g, " ").replace(/_/g, "-"); }else{ url = window.secureUnsecure + '' + cityValue.toLowerCase() + '/school/' + instiValUrl.toLowerCase() + '-in-' + localityValue.toLowerCase(); instituteName = instiVal.replace(/-/g, " ") + ', ' + localityValue.replace(/-/g, " ").replace(/_/g, "-") + ', ' + cityValue.replace(/-/g, " ").replace(/_/g, "-"); } }else if(type == 'COLLEGE'){ if(autoSuggestionData[type][inst].indexOf("-instituteId-") > -1){ url = window.secureUnsecure + '' + cityValue.toLowerCase() + '/collegeDetailPage/' + instiValUrl.toLowerCase() + '-in-' + localityValue.toLowerCase() + '?id='+instn[1]; instituteName = instiVal.replace(/-/g, " ") + ', ' + localityValue.replace(/-/g, " ").replace(/_/g, "-") + ', ' + cityValue.replace(/-/g, " ").replace(/_/g, "-"); }else{ url = window.secureUnsecure + '' + cityValue.toLowerCase() + '/college/' + instiValUrl.toLowerCase() + '-in-' + localityValue.toLowerCase(); instituteName = instiVal.replace(/-/g, " ") + ', ' + localityValue.replace(/-/g, " ").replace(/_/g, "-") + ', ' + cityValue.replace(/-/g, " ").replace(/_/g, "-"); } }else if(type == 'COACHINGCENTRE'){ url = window.secureUnsecure + '' + cityValue.toLowerCase() + '/coachingcentre/' + instiValUrl.toLowerCase() + '-in-' + localityValue.toLowerCase(); instituteName = instiVal.replace(/-/g, " ") + ', ' + localityValue.replace(/-/g, " ").replace(/_/g, "-") + ', ' + cityValue.replace(/-/g, " ").replace(/_/g, "-"); }else{ url = window.secureUnsecure + '' + city.replace(/ /g, "-") + '/college?q=' + qCourse.replace(/ /g, "+"); //url = window.secureUnsecure + 'search-microservice#?q='+qCourse.replace(/ /g, "+")+'&course='+qCourse.replace(/ /g, "+")+'&instituteType=COLLEGE&city='+city; instituteName = courseVal; } html += ''+ '
'+ '
'+ '
'+ '
'+ '

'+instituteName+'

'+ '
'+ '
'+ ''; } html += '
'+ ''+ ''; } } $('.bb-auto-mob-suggestive-list table tbody').append(html); }else{ html += ''+ ''+ '

'+ '

Result Not Found

'+ '
'+ ''; $('.bb-auto-mob-suggestive-list table tbody').append(html); } }, error: function (e) { console.log("something went wrong, please try again later.") } }); }); }); $(function(){ var _originalSize = $(window).width() + $(window).height() $(window).resize(function(){ if($(window).width() + $(window).height() != _originalSize){ console.log("keyboard show up"); $("#mob-floting-menu").hide(); }else{ console.log("keyboard closed"); $("#mob-floting-menu").show(); } }); });

congrats! we'll get back to you shortly.