• metate

    (@metate)


    Hi,
    I have created a new field in s2member and am trying to add it to an existing list. I have done this many times in the past without issue, so this is stumping me.
    I put sample data in the new field and Found New Fields and the field is listed as a choice (when configuring a list). When I put a number in its’ box and hit Update, it saves but nothing happens with the field – literally nothing like I never selected it. I tried it several times, I added more sample data, I tried it in a new list, I tried adding other fields I knew worked at the same time – and those added but the new field did not get added to the list. I googled for this issue but didn’t find anything.
    Can you help?
    Thank you!!!

    https://www.ads-software.com/plugins/amr-users/

Viewing 14 replies - 1 through 14 (of 14 total)
  • Plugin Author anmari

    (@anmari)

    Hi,

    1) have you rebuilt the cache ?

    2) what kind of field is it (text, checkbox, radio etc) ? and what kind of datavalues are in the field?

    S2member fields are not nice to play with as all the custom fields are stored in one usermeta record – rather than one meta record per custom field.
    In phpmyadmin for your sample user, look for yoursiteprex_s2member_custom_fields

    my example:
    a:3:{s:14:”classification”;s:18:”Legal and NonLegal”;s:7:”s2check”;s:1:”1″;s:7:”s2radio”;s:2:”BD”;}

    Thread Starter metate

    (@metate)

    thanks for the fast reply!
    1. rebuilt the cache on the list and went to user list> caching and rebuilt there. if there’s another place i should try, let me know!

    2. its’ a drop down with 15 values: Region 1, Region 2, Region 3, etc
    I’ll be able to look at myphpadmin tonight or tomorrow

    Thread Starter metate

    (@metate)

    From phpmyadmin, mysite_s2member_custom_fields is below. I replaced all individual information with xxx or 0s and the field that’s not showing up with the last one “region”. p.s. – I tried adding the field again just now (hoping time would help) and same issue.

    a:16:{s:15:”founder_charter”;a:1{i:0;s:8:”Founding”;}s:13:”business_name”;s:23:”xxx”;s:11:”web_address”;s:25:”xxx.com”;s:13:”facebook_page”;s:38:”www.facebook.com/xxx”;s:16:”physical_address”;s:9:”xx,xx”;s:12:”mailing_city”;s:5:”xxx”;s:13:”mailing_state”;s:2:”xx”;s:11:”mailing_zip”;s:5:”00000″;s:15:”mailing_country”;s:3:”USA”;s:12:”phone_number”;s:12:”000-000-0000″;s:19:”business_principals”;s:29:”xxx”;s:14:”business_focus”;a:1{i:0;s:13:”xxx”;}s:8:”why_join”;s:35:”xxx”;s:8:”how_find”;s:10:”xxx”;s:19:”volunteer_committee”;a:2{i:0;s:7:”xxx”;i:1;s:5:”xxx”;}s:6:”region”;s:9:”Region 12″;}

    Plugin Author anmari

    (@anmari)

    Hmm S2 member is not my favourite plugin to get data out of:
    Please read https://wpusersplugin.com/3086/user-lists-and-filtering-with-s2member-fields/ – see the bit about avoiding the multi choice options.

    It took me awhile to realise this but the other problem with testing with your data provided above is that you edited the data directly in phpmyadmin or edited the string without maintaining the integrity of the definition – primarily the strong sizes are wrong now – if you changed the data to ‘xxx’ then the string size should be 3.

    For example: this carefully edited bit works fine, the fields get identified
    a:2:{s:6:”region”;s:9:”Region 12″;s:13:”business_name”;s:3:”xxx”;}

    however with the nested arrays (multi – choice) and/or wrong string sizes, then it does not work.

    If you want to use my plugin, the link above explains alternate ways to structure the custom fields, or access the data if you are stuck on using S2member

    alternatively you could consider https://wpusersplugin.com/3195/possible-user-extra-field-or-user-meta-plugins/

    Thread Starter metate

    (@metate)

    So, it’s not a multi choice field – its just a drop down to pick one choice.
    Yeah, all I did was copy the string out of phpmyadmin, paste into notepad and change individual information to xs just so i could share it here – if you’re able to test with my data, I could email you the exact string? if so, what email would work?
    I will go read that link now – we are stuck with s2member.

    Thread Starter metate

    (@metate)

    Just to try something from your link, I changed the field from a dropdown to check boxes and ran into the same situation – the field would not be added to a list. Don’t know if that’s helpful or not…

    Thread Starter metate

    (@metate)

    I also tried making the field radio buttons….the field literally won’t add to the list….it just doesn’t make sense…

    Plugin Author anmari

    (@anmari)

    Remember the users plugin is looking at the data not the S2 settings. Just changing S2 settings is not going to work – I don’t think S2 updates the data.
    You’d have to make sure all your records are updated to reflect new settings (or delete them and create new data)

    Thread Starter metate

    (@metate)

    Okay, I was just hoping it might work. ??

    When you say make sure the records are updated to reflect new settings….what do you mean?

    Would you have any suggestions for things I can try or test? Or send you my data for your testing? I have to get a list of these Regions up for our members.
    Thank you for your time!

    Plugin Author anmari

    (@anmari)

    records = data (ie the user records).

    As stated above the plugin looks at the data, not the settings. If the data is still the same, the plugin will behave the same.

    Thread Starter metate

    (@metate)

    Okay, so, I created a new dummy single text line field, put data in it, and tried to add it to the same list – and it wouldn’t add either. We have several fields like this that have never had a problem being added to a list.
    It’s like there’s something up with the newest fields I’ve created (regardless of field structure) and they are being ignored/rejected or something?
    What specific things can I test/try?

    Plugin Author anmari

    (@anmari)

    Look S2 puts all that stuff (all the custom fields) into ONE value field.

    My plugin is generic and the way it treats these array values works for other data structures but not for the way S2 works. Your simple text field is probably sitting at the end of the S2 record which may or may not have corrupted data.

    If you want to pursue this then Make sure you have a CLEAN record to test with, so you not just adding data to the existing meta record. DELETE ALL the s2 member custom fields meta records for all the users using phpmyadmin.

    Then add the simple field you want to a user. Plugin should pick it up (did on my test for you above).
    Then add the next field to a user etc.

    Note:
    I have so far resisted adding custom specific ability to cope with these structures to the S2 member add-on, since most folks have managed to avoid getting into these sort of troubles bu either choosing different data structures or using other field creation plugins (or maybe even going a custom option themselves)

    Plugin Author anmari

    (@anmari)

    Hi – for the record, I just ran through ALL the s2member custom field types. They are picked up fine once there is sample data.

    So back to thinking you have some corrupted data – delete those records, start clean and it should pick them up.

    The only question then is whether you have chosen nice ‘codes’ for the values that work for display and filtering etc.

    Plugin Author anmari

    (@anmari)

    Me again – it’s a rainy sunday here. Instead of doing other things that I should have been doing, I updated https://wpusersplugin.com/downloads/amr-users-plus-s2-member/ – new version available.

    So I have now played around with all the S2 field types quite thoroughly and all come up fine.

    Please do let me know if a clean setup of your data sorted out your problem.

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Can't add field to list’ is closed to new replies.