WordPress.org

Ready to get started?Download WordPress

Forums

Advanced Custom Fields
[resolved] For those who have problems with magic fields plugin (3 posts)

  1. michapixel
    Member
    Posted 2 years ago #

    The Bug with the v. 1.x of Magic Fields, which some of you might have installed besides ACF, is that there seems to be a bug with WP which saves a post twice upon triggering the save button, which causes troubles. So MF and ACF both spawn a global variable named "$flag", which should indicate the save-state of the article. since both do use the same name, one of them overwrites the variable of the other, so whichever comes second does not save it's fields - this only affects newly created custom articles (made with magic fields). All existing articles stay untouched, as far as i can tell.

    There is a very simple solution, which should be future save: since magic fields isn't updated anymore, and if you do not have created many articles with it: replace it with some other plugin and migrate your articles to a more future-proof system / plugin. If however you cannot switch plugins, either because of too many articles that need to be migrated, or you really need some functionality of magic fields, either switch to version 2.x (which i really should not promote, since it's really spaghetti-code) or simply search-and-replace the "$flag"-variable with e.g. "$mc-flag". That should guarantee you all fields get saved.

    Hope that helps to save some time.

    http://wordpress.org/extend/plugins/advanced-custom-fields/

  2. elliotcondon
    Member
    Plugin Author

    Posted 2 years ago #

    Thanks Michapixel,

    I'll change the ACF global variable to help fix this issue.

    Cheers
    E

  3. michapixel
    Member
    Posted 2 years ago #

    Yeah, that might be a future-proof solution for acf too.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic