Link Vault for ExpressionEngine - Extension Hooks

Extend what you can do out of the box with our numerous extension hooks.

This hook is called immediately before a file is downloaded. The only parameter is the array of record data which can be manipulated within your extension but your method MUST return the record array.

Sample Code

$log_record_data = $this->EE->extensions->call('link_vault_download_start', $log_record_data);

This hook is called immediately after a file is downloaded and the download is logged.

Sample Code

$edata = $this->EE->extensions->call('link_vault_download_end', $log_record_data, $log_id);

This hook is called immediately before a remote download attempt is logged and the user's browser attempts to download the file. This hook accepts the record data array as a parameter. You can manipulate the record data in your extension and your hook method MUST return the record data array upon completion.

Sample Code

$log_record_data = $this->EE->extensions->call('link_vault_remote_download_start', $log_record_data);

This hook is called immediately before redirecting to a secure S3 URL. The hook must return the $log_record_data.

Sample Code

$log_record_data = $this->EE->extensions->call('link_vault_s3_download_start', $log_record_data);

This hook is called immediately before logging a leech attempt.

Sample Code

$record_data = $this->EE->extensions->call('link_vault_log_leech_start', $record_data);

This hook is called immediately after logging a leech attempt before the module checks to see if file leeching is allowed. Any value returned by the hook is not used in the module.

Sample Code

$edata = $this->EE->extensions->call('link_vault_log_leech_end', $record_data, $log_id);

This hook is called immediately before logging a link click. You can use this hook to modify the data that will be stored in the database row or manually populate a custom field. The record data array must be returned at the end of the hook method.

Sample Code

$record_data = $this->EE->extensions->call('link_vault_link_click_start', $record_data);