Support » Plugin: Just Custom Fields » [Plugin: Just Custom Fields] Custom field image settings dissapear when migrating from dev to live s

Viewing 1 replies (of 1 total)
  • I had the same problem, I managed to figure out what’s causing it and how to solve it.

    First of all, the values for your custom fields are store inside your wp_postmeta table, when you have an array as meta_value every string value is listed as the following:

    s:80:"http://www.mydomain.com/u/wp-content/uploads/2012/10/7897981874_2c580df195_z.jpg";

    I presume “s” stands for string, the number is the string length and the final value is your string, in this case an url.
    When you change the url in the string value, like so:

    s:80:"http://www.mynewdomain.com/u/wp-content/uploads/2012/10/7897981874_2c580df195_z.jpg";

    you end up changing the length of the string as well.
    The stated length (80) and the actual length of the string (83) don’t match anymore and that’s what’s causing the problem here.

    You have to update the numerical value of every url you changed (inside wp_postmeta) in order to get your images and files back.
    Like so:

    s:83:"http://www.mynewdomain.com/u/wp-content/uploads/2012/10/7897981874_2c580df195_z.jpg";

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: Just Custom Fields] Custom field image settings dissapear when migrating from dev to live s’ is closed to new replies.