Docs / Filter Reference / wpdm_download_lock

wpdm_download_lock

Description


If you want to add extra locks under Package Settings => Lock Options , you can use this hook.

Parameters


Two parameters are passed to this hook.

Usage


 

<?php add_filter('wpdm_download_lock','my_new_lock', 10, 2); ?>

Examples



<?php
add_filter( 'wpdm_download_lock', 'my_new_lock', 10, 2 );
function my_new_lock( $extra_lock, $package ) {
    $extra_lock['lock'] = 'locked'; // locked or empty
    $extra_lock['type'] = ''; //lock type
    $extra_lock['html'] = ''; //html code for extra lock

    return $extra_lock;
}

?>

Related


Last updated on January 26, 2026

Need Help?

Get support from our team or community forum.

Visit Support

Customization

Need custom features? We can help.

Request Quote