$(function () {
 
    $('#divNoConsultant').mouseenter(function () {
        $(this).addClass('locator_search_box_active');
        $('#divHasConsultant').removeClass('locator_search_box_active');
    });
    $('#divHasConsultant').mouseenter(function () {
        $(this).addClass('locator_search_box_active');
        $('#divNoConsultant').removeClass('locator_search_box_active');
    });
    $('.start_btn').click(function () {
        $('.start_btn').css({ 'display': 'block' });
        $('.search_filter_form').css({ 'display': 'none' });
        $(this).css({ 'display': 'none' });
        $(this).next('.search_filter_form').fadeIn();
    });
    $('input[name="filter_type"]').click(function () {
        if ($(this).val() == 'area') {
            $('.locator_search_right_type1').css({ 'display': 'block' });
            $('.locator_search_right_type2').css({ 'display': 'none' });
        }
        if ($(this).val() == 'id') {
            $('.locator_search_right_type2').css({ 'display': 'block' });
            $('.locator_search_right_type1').css({ 'display': 'none' });
        }
    });
    $('#search_by_id').click(function () {

        if ($('#search_by_id_textbox').val() == '') {
            $('#search_by_id_error').css('display', 'block');
        }
        else {
            $('#search_by_id_error').css('display', 'none');
        }
    });
});
function EmailCheck(email) {
    var reg = /^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+((\.[a-zA-Z0-9_-]{2,3}){1,2})$/;
    return reg.test(email);


}
