WordPress.org

Ready to get started?Download WordPress

Forums

WooCommerce - excelling eCommerce
Insert file path for downloadable product automatically getting double serialize (1 post)

  1. peteincali2103
    Member
    Posted 11 months ago #

    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?

    http://wordpress.org/plugins/woocommerce/

Reply

You must log in to post.

About this Plugin

About this Topic

  • RSS feed for this topic
  • Started 11 months ago by peteincali2103
  • This topic is not resolved
  • WordPress version: 3.6.1