Function Reference: geodir_cpt_remove_loc_on_search

Summary

Remove filter on location change on search page.

Change Log

Since: 1.1.6

Source File

geodir_cpt_remove_loc_on_search() is located in geodir_custom_posts/geodir_cp_functions.php [Line: 1394]

Source Code

function geodir_cpt_remove_loc_on_search() {
	$search_posttype = isset( $_REQUEST['stype'] ) ? $_REQUEST['stype'] : geodir_get_current_posttype();
	
	if ( geodir_cpt_no_location( $search_posttype ) ) {	
		remove_filter( 'init', 'geodir_change_loc_on_search' );
	}
}