Fields randomly deleted data

Support General Fields randomly deleted data

Viewing 15 posts - 1 through 15 (of 24 total)
  • Author
    Posts
  • #35173
    Ryan MaiettaRyan Maietta
    Participant

    I'm really, really discouraged. I spent a long time setting up events for this site. Each one has *many* courses and teachers. I added custom fields to a different set of custom fields for events. Refreshed the event. All the courses I filled in and their teachers are now empty. This isn't the first time this has happened and is an extremely terrible bug. I'm now looking at extra hours of unpaid work or paying someone to fill in all this data. I have a backup from this morning; but, that means losing a full day of work.

    Is there a way to get this data back?

    #35175
    Ryan MaiettaRyan Maietta
    Participant

    I was able to restore all but one of the relationships. It keeps deleting itself after being added. Unable to restore the fields still, which is the most important part. Where can I put admin credentials so the MB team can take a look at this?

    #35188
    Long NguyenLong Nguyen
    Moderator

    Hi Ryan,

    Can you please share some screenshots of the issue? Please follow this article to know how to increase the PHP setting max_input_vars to avoid losing data after saving post.
    https://metabox.io/wordpress-custom-fields-not-saving-increase-max-input-vars/

    And refer to this topic https://support.metabox.io/topic/cant-save-more-of-10-relationships-from-admin
    to avoid losing data if you add more than 10 connection items.

    #35192
    Ryan MaiettaRyan Maietta
    Participant

    I increased the max_input_vars to 10000 from 5000.

    On the backup, it looks like this:
    https://imgur.com/cPFcgrP

    On the current version, it looks like this:
    https://imgur.com/whlgaYX

    This was built using the GUI. Both object types are posts. Max items is unset.

    https://imgur.com/m1tCVDB
    Would I add "number" to the query args and set it as high as needed?

    (Additionally, the contact link on the pinned post is broken.
    https://imgur.com/LPv454t - for the Meta Box site)

    Thank you for your reply and your help.

    #35193
    Ryan MaiettaRyan Maietta
    Participant

    No luck unfortunately. It has the increased quantity, so that wasn't the issue. It overwrote the new, correct relationships with duplicates from the last three relationships that were there before.
    https://imgur.com/d7TF8tc

    I can't create the relationships via PHP if it means all the existing, functioning relationships will be wiped out. It's also worth noting this is working perfectly fine on every other event page. Since the contact form is broken (see last post), where do I send the admin credentials so this can be looked into?

    To save time, here are my other PHP settings:
    https://imgur.com/3Su4VWR

    #35228
    Long NguyenLong Nguyen
    Moderator

    Hi,

    Can you please share the code that creates the relationships on your site? Refer to this documentation https://docs.metabox.io/extensions/meta-box-builder/#getting-php-code

    #35232
    Ryan MaiettaRyan Maietta
    Participant

    https://pastebin.com/E6aGd1Cd

    Not sure what happened; but, I did these things a few hours ago and it started working again:
    - Added Cloudflare DNS API to GridPane and enabled SSL. It shouldn't be this one; but, I'm not sure.
    - Changed some AutomaticCSS framework settings; as far as I know, these changed only CSS variables.
    - Had to resign Oxygen shortcodes after enabling SSL. This is my best guess as to why it suddenly started working again. Something with the Oxygen-Meta Box integration may be broken.

    I was able to merge the SQL tables from the backup with the current version with no trouble this time.

    #35246
    Ryan MaiettaRyan Maietta
    Participant

    Nevermind. The fields deleted themselves (and their data) again after adding more fields to the page.

    Could the contact page please be fixed so we can send admin credentials? This is a really frustrating bug.

    https://imgur.com/13OAHM4

    #35247
    Ryan MaiettaRyan Maietta
    Participant

    I've posted this to the Oxygen and Meta Box Facebook groups to help gather information about why the bug is happening; but here's a video showing the glitch.

    https://www.loom.com/share/b90c7b9a66544f728cecfc5b89c58f33

    #35250
    Long NguyenLong Nguyen
    Moderator

    Hi,

    Thanks for your additional information.

    Looking in your screen record, I see there are many custom fields assigned to that post so I think increasing the setting max_input_vars to 10000 (10k) is not enough. Can you please increase a larger value (4-500k)?

    And use this code to save more connection items, currently, the option query_args in the builder is not working correctly.

    add_action( 'mb_relationships_init', 'ec_block1' );
    function ec_block1() {
        MB_Relationships_API::register( [
            'id'   => 'event-to-course-relationship',
            'from' => [
                'object_type'   => 'post',
                'post_type'     => 'events',
                'empty_message' => 'Choose an event',
                'field'         => [
                    'name'       => 'From Events to Courses',
                    'query_args' => [
                        'number' => 50 // This
                    ],
                ],
            ],
            'to'   => [
                'object_type'   => 'post',
                'post_type'     => 'course',
                'empty_message' => 'Choose a course',
                'field'         => [
                    'name' => 'To Course from Events',
                ],
            ],
        ] );
    }
    #35253
    Ryan MaiettaRyan Maietta
    Participant

    Thank you. I'll increase the value and see if that helps.

    Since I added the relationship through the GUI, will adding that code wipe out the current relationships? If so, is there anywhere I can add it or change so it won't do that?

    There are around 7 events total, each with a similar amount of fields.

    Thank you,
    Ryan

    #35255
    Long NguyenLong Nguyen
    Moderator

    Hi,

    You can temporarily disable this extension (or move to trash the relationship) and use the code to register the relationship to re-check this issue. The relationship data is saved to the database so it will not be lost if you disable this extension.

    Refer to this documentation https://docs.metabox.io/extensions/meta-box-builder/#getting-php-code

    #35256
    Ryan MaiettaRyan Maietta
    Participant

    Unfortunately neither of these worked. Re-importing the data or adding new relationships still results in the relationships deleting or cloning themselves. I included an admin link through the contact form I sent earlier.

    #35257
    Long NguyenLong Nguyen
    Moderator

    Hi,

    I've used the plugin Health Check to temporarily deactivate all plugins except Meta Box and Meta Box AIO then I can save more connection items as well. Can you please re-check it?
    wp-admin/post.php?post=122&action=edit

    #35259
    YasmineYasmine
    Participant

    I am also experiencing something similar. I am using Meta frontend and the post will save, but then if edited many of the taxonomies are no longer there. If try to readd, then I experience a fatal error. Unsure sure how to fix, but its really problematic

Viewing 15 posts - 1 through 15 (of 24 total)
  • You must be logged in to reply to this topic.