• Resolved sgano

    (@sgano)


    Hi there —

    I’m using Participants Database in conjunction with WordPress Users, per your excellent instructions, and that is working fine. Except that I’d like to use the hidden dynamic field, user_login, which is dynamically set to current_user->user_login, as the field to check for duplicate records.

    However, in the Signup Form Settings, the “Duplicate Record Check Field” option menu doesn’t include the user_login field. Is there any way I can use that hidden dynamic field to check for a duplicate record on signup?

    Thanks!
    –steve.

    https://wordpress.org/plugins/participants-database/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author xnau webdesign

    (@xnau)

    Well, that is a good point, it could be useful.

    I wlll look into how that might be changed, but in the meantime, you can work around it by temporarily changing the user login hidden field to a text field, then select it in the settings. Once that’s done, you can change the field back to a hidden field.

    The problem with the workaround is that if you save the settings again, you’ll lose that setting.

    The plugin could also to be modified to allow a hidden field to be the check field, not sure what that would entail at the moment.

    Thread Starter sgano

    (@sgano)

    Nice workaround, thanks! But yeah, looks like you lose it if you save any of the settings, not just the Signup Form Settings.

    Here’s what I tried, and so far it seems to be working. In PDb_Settings.class.php, in the plugin_settings block for ‘Duplicate Record Check Field’ (around line 311), I added _get_identifier_columns() to the options array:


    'options' => array_merge($this->_get_display_columns(), $this->_get_identifier_columns(), array('Record ID' => 'id')),

    That adds my hidden user_login field to the menu.

    I’ll report back if I see some problems with this down the line. OR do say if you think this could be a problem.
    thanks!
    –steve.

    Plugin Author xnau webdesign

    (@xnau)

    Good fix. I’m going to open this up in the next release so hidden fields can be used here. Thanks for the great suggestion.

    Thread Starter sgano

    (@sgano)

    My pleasure, thanks for the great plug-in!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Duplicate Record Check Field doesn't show option I need’ is closed to new replies.