1

I have this data code and I need the data in PHP array/object format, anyone recognizes this?

It looks like json but its not. I have pulled it from a WordPress database

a:3:{i:0;a:10:{s:17:"availability_type";s:6:"custom";s:9:"from_date";s:16:"2020-05-14 18:00";s:13:"from_week_day";s:1:"1";s:10:"from_month";s:1:"1";s:9:"from_time";s:0:"";s:11:"to_week_day";s:1:"1";s:8:"to_month";s:1:"1";s:7:"to_date";s:16:"2020-05-14 18:00";s:7:"to_time";s:0:"";s:10:"is_bokable";s:3:"yes";}i:1;a:10:{s:17:"availability_type";s:6:"custom";s:9:"from_date";s:11:"2020-05-15 ";s:13:"from_week_day";s:1:"1";s:10:"from_month";s:1:"1";s:9:"from_time";s:0:"";s:11:"to_week_day";s:1:"1";s:8:"to_month";s:1:"1";s:7:"to_date";s:11:"2020-05-15 ";s:7:"to_time";s:0:"";s:10:"is_bokable";s:3:"yes";}i:2;a:10:{s:17:"availability_type";s:6:"custom";s:9:"from_date";s:11:"2020-05-27 ";s:13:"from_week_day";s:1:"1";s:10:"from_month";s:1:"1";s:9:"from_time";s:0:"";s:11:"to_week_day";s:1:"1";s:8:"to_month";s:1:"1";s:7:"to_date";s:11:"2020-05-27 ";s:7:"to_time";s:0:"";s:10:"is_bokable";s:3:"yes";}}
1

1 Answer 1

2

Sorry for my bad english. This is a serialized string, you can use unserialize() to convert to an array.

https://www.php.net/unserialize

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.