WordPress.org

Support

Support » Plugins and Hacks » Events Manager » [Resolved] Registration Form Errors: Added Fields

[Resolved] Registration Form Errors: Added Fields

  • Fantastic plug-in….

    There is some additional information we need to collect when someone registers for an event for the first time.

    1. I went to the wp_users table and added these fields: CameraMake, CameraModel, VoucherType and VoucherNumber. All are text. None were required.

    2. Before I could add them to the registration form for an event, I was testing the registration process using a test user. I filled in Name, email and phone. I immediately got the following errors:

    ERROR: couldn’t be empty
    ERROR: Camera Model couldn’t be empty
    ERROR: Camera Model couldn’t have a lenght less than 5
    ERROR: Voucher Number couldn’t be empty.
    ERROR: Voucher Number couldn’t be less than 5.

    3. I went into the database and removed the columns. The error still persisted.

    4. I added the columns back. This time I added default values. I can see the default values when I use a sign-up form on the site.

    5. I added the fields to the event registration page – I edit the Booking-fields.php form. I can see them but I am still getting these errors.

    6. In Chrome I have enabled developers tools so I can see the errors in the code. I can’t find which php module is generating them.

    7. I also need to know where in the code I need to put the statements that will load this information into the wp_users table.

    Unfortunately I thought I was on the test server when I was doing this. It seems I wasn’t. So, at the moment, new users can’t register.

    Your help is appreciated.

    http://wordpress.org/extend/plugins/events-manager/

Viewing 7 replies - 1 through 7 (of 7 total)
  • Modifications made to booking-fields.php:

    <p>
    <label for=’CameraMake’><?php _e(‘Camera Make’,’dbem’) ?></label>
    <input type=”text” name=”CameraMake” id=”CameraMake” class=”input” value=”<?php if(!empty($_REQUEST[‘CameraMake’])) echo esc_attr($_REQUEST[‘CameraMake’]); ?>” />
    </p>
    <p>
    <label for=’CameraModel’><?php _e(‘Camera Model’,’dbem’) ?></label>
    <input type=”text” name=”CameraModel” id=”CameraModel” class=”input” value=”<?php if(!empty($_REQUEST[‘CameraModel’])) echo esc_attr($_REQUEST[‘CameraModel’]); ?>” />
    </p>
    <p>
    <label for=’VoucherType’><?php _e(‘VoucherType’,’dbem’) ?></label>
    <input type=”text” name=”VoucherType” id=”VoucherType” class=”input” value=”<?php if(!empty($_REQUEST[‘VoucherType’])) echo esc_attr($_REQUEST[‘VoucherType’]); ?>” />
    </p>
    <p>
    <label for=’VoucherNumber’><?php _e(‘VoucherNumber’,’dbem’) ?></label>
    <input type=”text” name=”VoucherNumber” id=”VoucherNumber” class=”input” value=”<?php if(!empty($_REQUEST[‘VoucherNumber’])) echo esc_attr($_REQUEST[‘VoucherNumber’]); ?>” />
    </p>

    I have temporarily disabled the option to allow guests to register. Getting too many calls.

    If you’re getting error messages about your new fields not being filled in that suggests the saving process is working. Is that right?

    Does that mean the only remaining problem is that the fields are being treated as required when they shouldn’t?

    No, the record isn’t being saved.

    Now, let me qualify that. If the user uses the Create an Account option, the record is saved. It is not saved if it is created at the registration page.

    The error is coming from bookingsform.js apparently.

    Update:

    I deleted the plugin files and copied them to the server again. That ended the problem. Mostly. I have some others that need ironing out but at the moment it is at least functional

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘[Resolved] Registration Form Errors: Added Fields’ is closed to new replies.
Skip to toolbar