Fields not showing: Warning: Invalid argument supplied for foreach()

Support General Fields not showing: Warning: Invalid argument supplied for foreach()Resolved

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #13812
    AleAle
    Participant

    Hello Anh,

    Today after the update of MB I start getting this messages randomly in some fields (image_advanced) please check how it currently is: https://www.colorale.com/work/dji-com/

    If I re-upload the images some are fixed but after I save I get the same error in the fixed one or in other fields.

    #13813
    Anh TranAnh Tran
    Keymaster

    Hi Ale, can you post the code you use on those locations?

    #13817
    AleAle
    Participant

    Here's the relevant part of the code.

    the line with Warning: Invalid argument supplied for foreach() is the one with:

    foreach ( $image_fields as $object_img ) {

    #13840
    Anh TranAnh Tran
    Keymaster

    Hi Ale, can you var_dump( $image_fields ) to see what values it has?

    #13842
    AleAle
    Participant

    I re-uploaded one image and then that one and others start showing up, this is what I get with the images that are being displayed: array(1) { [0]=> string(4) "1227" }

    I've tried to re upload all images and the message Warning: Invalid argument supplied for foreach() randomly shows in some images every time I update.

    ??‍♂️

    #13863
    Anh TranAnh Tran
    Keymaster

    Can you send me a temporary admin account to check and fix that?

    #13865
    AleAle
    Participant

    Email sent, thanks.

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