The Iptanus File Upload plugin supports a set of filters and actions for tailoring it to what you need; the full list is in a separate article.
Since version 3.6.0 you can write the code for them inside the plugin itself, from its Dashboard area, with no third-party plugin involved.
Say you want some JavaScript to run as soon as a file has been uploaded. That means implementing the wfu_after_file_upload filter.
Creating a hook
Go to the plugin’s area in the Dashboard, open the Hooks tab, and create a new hook:
The screen that opens asks for a title, a description, the code, a status (active or not), and where the hook should run — in the Dashboard or on the front end. Fill in a title and description of your own.
Filling in the code
Above the code box sit code templates, which save you writing a filter from scratch. Choose “After File Upload Filter” and press “Add Code“. The box fills with the filter function and comments explaining how to use it:
Edit it so that a success message pops up when a file has uploaded. The finished code looks like this:
Set the Status to Active and press Save.
If the code is sound, the new hook appears in the hook list. If it is not, a message at the top of the screen explains the error and the hook is left inactive:
From that screen you can activate, deactivate or delete a hook, and run bulk actions across several at once.
Trying it out
With the filter in place, upload a file from a page. Once it has uploaded, the message appears:
For more information or questions about the Hooks feature, please contact us.
The Iptanus team







Hello,
[Sorry for my english, I’m French]
I’d like add one custom field with a default value but not display it in the upload page.
I could use Css to hide these field, but I’d prefer do it without indication of these field in the code page.
Is it possible with the hook system to add code in order to add one “userdata_field” before call the function “wfu_log_action” and like that have one record in the wfu_userdata table with the custom field I’d like to record ?
I hope I’m clear.
Thanks
Can I change the table tr td structure for a only divs and put some clases? Something like custom code display?
Hi, you mean the frontend file viewer?
Nickolas
Hello, I am trying to add a hook to wfu_after_file_upload and I have 2 questions:
1) I need go into WP database and add some info to a table in WP database, so I need to execute an action on server side. Is it possible to create a hook similar to “wfu_after_file_upload” but on server side in functions.php?
2) Is there shortcode or a variable I can access from server side in PHP to fetch the name of the file the user just uploaded? I looked in the WP database but could not find any uploaded files in wp_posts or any other tables that would give me that information.
I am a mediocre programmer who greatly appreciate any suggestions. Thanks!