'', 'place_lng' => '', 'place_label' => '', 'radius_km' => 20, 'activity_types' => '', ), $atts, 'rfcc_location_filter' ); if ( ! function_exists( 'rfcc_v2_shortcode' ) ) { return '
' . esc_html__( 'Route Finder V2 is not available.', 'route-finder' ) . '
'; } $lat = ( $atts['place_lat'] !== '' && is_numeric( $atts['place_lat'] ) ) ? (float) $atts['place_lat'] : null; $lng = ( $atts['place_lng'] !== '' && is_numeric( $atts['place_lng'] ) ) ? (float) $atts['place_lng'] : null; $radius = is_numeric( $atts['radius_km'] ) && (float) $atts['radius_km'] > 0 ? (float) $atts['radius_km'] : rfcc_get_location_discovery_default_radius_km(); if ( null !== $lat && null !== $lng && $lat >= -90 && $lat <= 90 && $lng >= -180 && $lng <= 180 ) { // Deliberately only sets near_lat/near_lng/near_radius when they // aren't already present in the URL — a visitor who has already // adjusted (or cleared) the Near a Place filter and then navigates // back/forward, or re-shares the URL themselves, keeps their own // state rather than being reset to this block's configured place on // every load. // // Attached as inline JS 'before' the rfcc-v2-script handle (rather // than echoed as a raw