1

I have data for buddypress in table named "wp_bp_xprofile_data" which has fields like

"a:2:{i:0;s:10:"myproject";i:1;s:5:"Other";}"

What kind of data it is ? surely its not JSON ...

Mark
  • 1,381
  • 5
  • 18
  • 21

2 Answers2

2

It's PHP serialised data. You can parse it out with unserialize()

http://php.net/manual/en/function.unserialize.php

James C
  • 14,047
  • 1
  • 34
  • 43
1

Re serialized profile data:

$value = bp_get_profile_field_data(‘field=some_serialized_field’);
$value = bp_unserialize_profile_field($value);
shanebp
  • 11
  • 1