1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.3 Change Custom user field type

Discussion in 'Styling and Customization Questions' started by upnet, Aug 28, 2014.

  1. upnet

    upnet Active Member

    Is it possible to change an existing customer user field from a radio button to a checkbox type? I have been using the field for awhile so there are a lot of users with data in there, but I want to allow them to have multiple choices on the field.
     
  2. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Those are really different data structures. The data is stored differently so you can't just change the field type.

    I would recommend creating a new field and then copying the information. Here is an example:

    https://xenforo.com/community/threads/sql-query-to-transfer-info-between-fields.38648/#post-427064

    But multi-select fields store values as arrays. You will need to examine and test how data is stored for both fields in that table to construct an appropriate query to copy the data.

    Take a backup before doing this.
     

Share This Page