# One Fluent Forms Submission per Logged-In User

> Lets each logged-in member submit the Fluent Forms forms you choose only once, which suits surveys, votes and applications, with a clear message on a second attempt.

- Type: PHP
- Runs: Run everywhere
- Category: [Forms](https://wpide.com/library/category/forms/)
- Tags: fluent-forms, members, limits
- Author: WPIDE Team
- Installs: 0
- Updated: 2026-10-28
- Page: https://wpide.com/library/fluentforms-one-submission-per-user/

## Code

```php
$wpide_ff_once_forms   = array(); // Form IDs, e.g. array( 1 ).
$wpide_ff_once_message = 'You have already submitted this form. Thank you!';

add_filter( 'fluentform/validation_errors', function ( $errors, $data, $form ) use ( $wpide_ff_once_forms, $wpide_ff_once_message ) {
    if ( is_user_logged_in() && in_array( (int) $form->id, array_map( 'intval', $wpide_ff_once_forms ), true ) && get_user_meta( get_current_user_id(), '_wpide_ff_done_' . (int) $form->id, true ) ) {
        $errors['_wpide_once'] = array( $wpide_ff_once_message );
    }

    return $errors;
}, 10, 3 );

add_action( 'fluentform/submission_inserted', function ( $entry_id, $data, $form ) use ( $wpide_ff_once_forms ) {
    if ( is_user_logged_in() && in_array( (int) $form->id, array_map( 'intval', $wpide_ff_once_forms ), true ) ) {
        update_user_meta( get_current_user_id(), '_wpide_ff_done_' . (int) $form->id, time() );
    }
}, 10, 3 );
```

## Notes

List the form IDs at the top; submissions are remembered in user meta and logged-out visitors are not limited.

## How to use it

Install the free WPIDE plugin (https://wordpress.org/plugins/wpide/), find "One Fluent Forms Submission per Logged-In User" in its snippet library and add it in one click; or create a new PHP snippet in WPIDE (or any code snippets plugin) and paste the code above. More snippets: https://wpide.com/library/
