wpsl_draggable_map

  1. Description
  2. Usage
  3. Changelog
  4. Source File

Description

This filter is deprecated and replaced by the wpsl_gesture_handling filter.

This filter enables you to change the dragging option for the map.

If dragging is enabled, then you can define a width from which the dragging is disabled again.

Disabling the dragging option on smaller screens prevents users from getting stuck on the map if they are scrolling down the page and can’t get past the map.

The default setting disables the dragging option if the screen width is smaller than 675 pixels. The same break point is used in the WPSL styles.css to make the map 100% wide.

Usage

This example disables the dragging on all screen formats:

This example enables the dragging, but disables it on screens smaller than 800 pixels:

Changelog

Since 2.1

Source File

This filter is located in /frontend/class-frontend.php

Placement

The code needs to be placed in the functions.php file inside your active theme folder.