Skip to main content

Filter: gk/gravityexport/download/can-download

Modifies whether the current user may download a secured export.

Runs only for secured GravityExport Lite download URLs; a public download URL is always served. Downloads that other GravityExport add-ons serve through their own URLs are checked by those add-ons. Return true to allow a user who lacks the gravityforms_export_entries capability, or false to refuse one who has it. It can run more than once for one download (GravityExport asks it again for its Filters download URLs), so a callback should give the same answer each time.

Parameters​

NameTypeDescription
$can_downloadboolWhether the user has the gravityforms_export_entries capability.
$feedarrayThe feed being downloaded; an empty array when the form has no export feed.
$user_idintThe current user's ID, or 0 for a visitor who is not logged in.

Since​

  • 2.7.6

Source​

Defined in src/GFExcel.php at line 276