• Hi everyone. I am having regarding add_post_meta / update_post_meta double serializing a serialized string that is pre constructed.

    Basically I am trying to insert a preserialized string using add_post_meta to a product automatically when another post type is created. However, the string is getting double serialized, so for example, the preserialized string is:

    a:1:{s:32:”pH98SYKFExGdZvJfM4rtgN2cC16ARkqB”;s:54:”file_path”;}

    Turns in to:

    s:97:”
    a:1:{s:32:”pH98SYKFExGdZvJfM4rtgN2cC16ARkqB”;s:54:”file_path”;}
    “;

    I realize that add post meta is supposed to serialize data for you automatically, but I just want to insert the string as is. Does anyone have any idea how I can do this?

    https://www.ads-software.com/plugins/woocommerce/

  • The topic ‘Insert file path for downloadable product automatically getting double serialize’ is closed to new replies.