Additional "name" fields in form

This topic contains 2 replies, has 2 voices, and was last updated by  CupOfTea696 9 years, 4 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #18360

    Hi,

    I was wondering if you guys could add the possibility to add additional “name” fields in the admin form editor. At the moment I’m using a normal input field but it looks a little odd since the name field above is two input fields on one line, and the additional name is either only one field or two fields but on separate rows.

    Thanks in advance!

    CupOfTea696
    #18372

    There’s no UI to add a ‘name’ field – though this may change. But you can add a name field using the form API: http://wp-event-organiser.com/blog/tutorial/using-form-api-add-additional-fields/ (where the type parameter is name).

    The name field additional arguments to your standard element:

    • label_fname – The label of the first name field
    • label_lname – The label of the last name field
    • lname – (bool) Whether a last name field should be included
    • lname_required – (bool) Whether the last name is required
    Stephen Harris
    #18373

    Awesome, thanks!

    CupOfTea696
Viewing 3 posts - 1 through 3 (of 3 total)
To enable me to focus on Pro customers, only users who have a valid license for the Pro add-on may post new topics or replies in this forum. If you have a valid license, please log-in or register an account using the e-mail address you purchased the license with. If you don't you can purchase one here. Or there's always the WordPress repository forum.