• Hello,

    I have attachments plugin version 3.5.3 installed on WordPress 3.8.1 I am also running Easy Content Types 2.7.2 and Easy Content Types Bonus Meta Field types 1.1.5.

    When I edit an existing post and just save it, no changes, then at random some attachments are lost. I have checked the database and noticed that the meta_value field for the attachments meta_key for the specific post was indeed changed.

    So for some reason the attachment meta_value is changed when saving, even if there are not changes made in the post.

    Is there any clue to this issue?

    Regards,
    Bart

    https://wordpress.org/plugins/attachments/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter bart77

    (@bart77)

    Just some more information I just found. I analysed the POST data using Fiddler and noticed this:

    attachments[sec_attachments][5315b67bb34a7][id] 3242
    attachments[sec_attachments][5315b67bb34a7][fields][title] 3
    attachments[sec_attachments][5315b67bb34a7][fields][datum]
    attachments[sec_attachments][5315b67be1113][id] 3243
    attachments[sec_attachments][5315b67be1113][fields][title] 2
    attachments[sec_attachments][5315b67be1113][fields][datum]
    attachments[sec_attachments][5315b67be1113][id] 3251
    attachments[sec_attachments][5315b67be1113][fields][title] 1
    attachments[sec_attachments][5315b67be1113][fields][datum]
    attachments[sec_attachments][5315b67be1113][id] 3248
    attachments[sec_attachments][5315b67be1113][fields][title] 4
    attachments[sec_attachments][5315b67be1113][fields][datum]
    attachments[sec_attachments][5315b67be1113][id] 3242
    attachments[sec_attachments][5315b67be1113][fields][title] 5
    attachments[sec_attachments][5315b67be1113][fields][datum]

    As you can see there are 5 attachments, however the last 4 attachments all have the same GUID/ID in the POST array. That won’t work ofcourse.

    Thread Starter bart77

    (@bart77)

    Okay so I found the cause and solved it, however I’m not sure why the solution is working…

    I’m was running PHP 5.5.8 on Windows server. The attachments plugin didn’t work as expected anymore. ID’s in the attachment list recieved the same UID randomly (or so it seemed).

    I changed back to PHP 5.4.9 (on the same Windows server) and now it works like it should again!

    I could not find any logical explanation in the changelog from 5.4.x to 5.5.x myself though: http://www.php.net/manual/en/migration55.incompatible.php

    Plugin Author Jon Christopher

    (@jchristopher)

    Hi Bart, thank you for all of the helpful information! That’s definitely strange indeed. I’ll have to get that specific environment set up on my end and see if there’s anything I can do to resolve that particular incompatibility. Thank you again for being so thorough, that helps so much.

    Hello! I’m having the same issue. I’m on PHP 5.3.28 on Apache 2.2.x. Latest wordpress, with a commercial theme (firebricks). From an empty portfolio, based on Attachments plugin (latest release), i can add 12 images without problem when I save the page.
    If I save it again, some random images are deleted. And so on, everytime I save, I got 1 or more images deleted.
    Checking the source code of the theme seems fine.
    Where can I check for getting more clues/details?
    Thanks a lot!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘After saving, random attachments are deleted?’ is closed to new replies.