gpt4 book ai didi

php - 将 Wordpress sql 值转换为纯文本

转载 作者:行者123 更新时间:2023-11-29 10:30:36 25 4
gpt4 key购买 nike

Wordpress postmeta 数据库:

meta_id post_id     meta_key          meta_value 
1 1 foodbakery_menu_items a:64:{i:0;a:7:{s:15:"menu_item_title";s:37:"Chicken Tandoori Special 12" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:35:"Cheese tomatoes, and italian herbs.";s:14:"menu_item_icon";s:4:"3699";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"4.5";s:15:"menu_item_extra";a:1:{s:7:"heading";a:1:{i:0;s:0:"";}}}i:1;a:7:{s:15:"menu_item_title";s:38:"Chicken Tandoori Special 09" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:53:"Cheese tomatoes tuna fish sweetcorn and italian herbs";s:14:"menu_item_icon";s:4:"3698";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"6.50";s:15:"menu_item_extra";a:2:{s:7:"heading";a:2:{i:0;s:6:"Drinks";i:1;s:0:"";}i:0;a:2:{s:5:"title";a:3:{i:0;s:10:"Cold Drink";i:1;s:7:"Redbull";i:2;s:8:"chillies";}s:5:"price";a:3:{i:0;s:3:"1.5";i:1;s:3:"2.5";i:2;s:3:"3.5";}}}}i:2;a:7:{s:15:"menu_item_title";s:23:"Margherita 12" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:32:"heese tomatoes and italian herbs";s:14:"menu_item_icon";s:4:"3696";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"5.50";s:15:"menu_item_extra";s:0:"";}i:3;a:7:{s:15:"menu_item_title";s:23:" Margherita 9" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:71:"Cheese tomatoes shrimps garlic mussels cockles olives and italian herbs";s:14:"menu_item_icon";s:0:"";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.50";s:15:"menu_item_extra";s:0:"";}i:4;a:7:{s:15:"menu_item_title";s:23:" Margherita 9" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:33:"Cheese tomatoes and italian herbs";s:14:"menu_item_icon";s:4:"3694";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.50";s:15:"menu_item_extra";s:0:"";}i:5;a:7:{s:15:"menu_item_title";s:23:"Vegetarian 12" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:71:"Cheese tomatoes shrimps garlic mussels cockles olives and italian herbs";s:14:"menu_item_icon";s:4:"3693";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.50";s:15:"menu_item_extra";s:0:"";}i:6;a:7:{s:15:"menu_item_title";s:31:"Foodbakery Special 12" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:43:"Cheese tomatoes mushrooms and italian herbs";s:14:"menu_item_icon";s:4:"3691";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.90";s:15:"menu_item_extra";s:0:"";}i:7;a:7:{s:15:"menu_item_title";s:30:"Foodbakery Special 9" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:71:"Cheese tomatoes shrimps garlic mussels cockles olives and italian herbs";s:14:"menu_item_icon";s:4:"3690";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.80";s:15:"menu_item_extra";s:0:"";}i:8;a:7:{s:15:"menu_item_title";s:30:"Foodbakery Special 9" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:43:"Cheese tomatoes mushrooms and italian herbs";s:14:"menu_item_icon";s:4:"3689";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.80";s:15:"menu_item_extra";s:0:"";}i:9;a:7:{s:15:"menu_item_title";s:22:"Calzone (Folded Pizza)";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:69:"Cheese tomatoes ham salami mushrooms garlic sausage and italian herbs";s:14:"menu_item_icon";s:4:"3688";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"3.5";s:15:"menu_item_extra";a:2:{s:7:"heading";a:2:{i:0;s:6:"Extras";i:1;s:0:"";}i:0;a:2:{s:5:"title";a:3:{i:0;s:10:"Cold Drink";i:1;s:5:"Souce";i:2;s:5:"Chees";}s:5:"price";a:3:{i:0;s:3:"2.5";i:1;s:3:"1.5";i:2;s:3:"0.8";}}}}i:10;a:7:{s:15:"menu_item_title";s:27:"Garlic Pizza Bread 9 " Thin";s:15:"restaurant_menu";s:12:"Garlic Bread";s:21:"menu_item_description";s:61:"Butter and crushed garlic then spread a little over the pizza";s:14:"menu_item_icon";s:4:"3687";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"2.5";s:15:"menu_item_extra";s:0:"";}i:11;a:7:{s:15:"menu_item_title";s:21:"Garlic Bread 12" Deep";s:15:"restaurant_menu";s:12:"Garlic Bread";s:21:"menu_item_description";s:44:"Pizza bread made with extra virgin olive oil";s:14:"menu_item_icon";s:4:"3685";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"3.5";s:15:"menu_item_extra";s:0:"";}i:12;a:7:{s:15:"menu_item_title";s:27:"Garlic Pizza Bread 12" Thin";s:15:"restaurant_menu";s:6:"Kebabs";s:21:"menu_item_description";s:50:"Tomatoes garlic oregano and extra virgin olive oil";s:14:"menu_item_icon";s:4:"3684";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"2.5";s:15:"menu_item_extra";s:0:"";}i:13;a:7:{s:15:"menu_item_title";s:13:"Regular Kebab";s:15:"restaurant_menu";s:6:"Kebabs";s:21:"menu_item_description";s:75:"Beef meat split chickpealentils ginger garlic onions salt and mixed spices";s:14:"menu_item_icon";s:3:"108";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"3.0";s:15:"menu_item_extra";s:0:"";}i:14;a:7:{s:15:"menu_item_title";s:16:"Kebabs With Naan";s:15:"restaurant_menu";s:6:"Kebabs";s:21:"menu_item_description";s:42:"Kebab is a dish of pieces of meat and fish";s:14:"menu_item_icon";s:4:"1628";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.50";s:15:"menu_item_extra";s:0:"";}i:15;a:7:{s:15:"menu_item_title";s:20:"Chapal Kebab Regular";s:15:"restaurant_menu";s:6:"Kebabs";s:21:"menu_item_description";s:52:"Kababs made with minced mutton meat is a famous dish";s:14:"menu_item_icon";s:3:"107";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.50";s:15:"menu_item_extra";s:0:"";}i:16;a:7:{s:15:"menu_item_title";s:15:"Kebabs With nan";s:15:"restaurant_menu";s:6:"Kebabs";s:21:"menu_item_description";s:73:"For the kebabs: Preheat a tandoor oven or a charcoal grill to medium heat";s:14:"menu_item_icon";s:4:"1645";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"2.0";s:15:"menu_item_extra";s:0:"";}i:17;a:7:{s:15:"menu_item_title";s:21:"Chicken Kebab Regular";s:15:"restaurant_menu";s:6:"Kebabs";s:21:"menu_item_description";s:52:"Kababs made with minced mutton meat is a famous dish";s:14:"menu_item_icon";s:4:"1635";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"6.5";s:15:"menu_item_extra";s:0:"";}i:18;a:7:{s:15:"menu_item_title";s:22:"Chicken Kebab With Nan";s:15:"restaurant_menu";s:6:"Kebabs";s:21:"menu_item_description";s:103:"Prepare a Tandoor or charcoal grill for moderate heat. Thread the marinated chicken onto a metal skewer";s:14:"menu_item_icon";s:4:"1632";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"3.5";s:15:"menu_item_extra";s:0:"";}i:19;a:7:{s:15:"menu_item_title";s:26:"Chicken Boti Kebab Regular";s:15:"restaurant_menu";s:6:"Kebabs";s:21:"menu_item_description";s:73:"For this extremely tasty recipe you just need chicken almond and spices. ";s:14:"menu_item_icon";s:3:"106";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"8.50";s:15:"menu_item_extra";s:0:"";}i:20;a:7:{s:15:"menu_item_title";s:27:"Chicken Boti Kebab with nan";s:15:"restaurant_menu";s:6:"Kebabs";s:21:"menu_item_description";s:78:"For this extremely tasty recipe you just need naan chicken almond and spices. ";s:14:"menu_item_icon";s:4:"3684";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"8.50";s:15:"menu_item_extra";s:0:"";}i:21;a:7:{s:15:"menu_item_title";s:12:"Cheeseburger";s:15:"restaurant_menu";s:7:"Burgers";s:21:"menu_item_description";s:32:"Topped with pineapple and cheese";s:14:"menu_item_icon";s:4:"1645";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:1:"6";s:15:"menu_item_extra";s:0:"";}i:22;a:7:{s:15:"menu_item_title";s:12:"Half Pounder";s:15:"restaurant_menu";s:7:"Burgers";s:21:"menu_item_description";s:32:"Topped with pineapple and cheese";s:14:"menu_item_icon";s:3:"115";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:1:"2";s:15:"menu_item_extra";s:0:"";}i:23;a:7:{s:15:"menu_item_title";s:17:"Half Pounder Meal";s:15:"restaurant_menu";s:7:"Burgers";s:21:"menu_item_description";s:32:"Topped with 1000 island dressing";s:14:"menu_item_icon";s:3:"117";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.50";s:15:"menu_item_extra";s:0:"";}i:24;a:7:{s:15:"menu_item_title";s:20:"Quarter Pounder Meal";s:15:"restaurant_menu";s:7:"Burgers";s:21:"menu_item_description";s:18:"Topped with cheese";s:14:"menu_item_icon";s:3:"116";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"2.99";s:15:"menu_item_extra";s:0:"";}i:25;a:7:{s:15:"menu_item_title";s:13:"Chilli Burger";s:15:"restaurant_menu";s:7:"Burgers";s:21:"menu_item_description";s:76:"Topped with mozzarella cheese tomato relish cheddar cheese and green peppers";s:14:"menu_item_icon";s:3:"112";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:1:"4";s:15:"menu_item_extra";s:0:"";}i:26;a:7:{s:15:"menu_item_title";s:26:"Chilli Burger Half Pounder";s:15:"restaurant_menu";s:7:"Burgers";s:21:"menu_item_description";s:20:"Topped with coleslaw";s:14:"menu_item_icon";s:4:"1629";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"2.00";s:15:"menu_item_extra";s:0:"";}i:27;a:7:{s:15:"menu_item_title";s:31:"Chilli Burger Half Pounder Meal";s:15:"restaurant_menu";s:7:"Burgers";s:21:"menu_item_description";s:30:"Topped with spicy chilli sauce";s:14:"menu_item_icon";s:4:"1633";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.50";s:15:"menu_item_extra";s:0:"";}i:28;a:7:{s:15:"menu_item_title";s:11:"Donner Meat";s:15:"restaurant_menu";s:8:"Specials";s:21:"menu_item_description";s:82:"Prepared with onions capsicums garlic fresh tomatoes and chefs own selected spices";s:14:"menu_item_icon";s:4:"1636";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.00";s:15:"menu_item_extra";s:0:"";}i:29;a:7:{s:15:"menu_item_title";s:12:"Chicken Meat";s:15:"restaurant_menu";s:8:"Specials";s:21:"menu_item_description";s:82:"Prepared with onions capsicums garlic fresh tomatoes and chefs own selected spices";s:14:"menu_item_icon";s:4:"3688";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.90";s:15:"menu_item_extra";s:0:"";}i:30;a:7:{s:15:"menu_item_title";s:12:"Chicken Wrap";s:15:"restaurant_menu";s:5:"Wraps";s:21:"menu_item_description";s:88:"Sliced grilled chicken breast nestled in a fresh mix of Green Leaf lettuce with shredded";s:14:"menu_item_icon";s:4:"3687";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.00";s:15:"menu_item_extra";s:0:"";}i:31;a:7:{s:15:"menu_item_title";s:11:"Donner Wrap";s:15:"restaurant_menu";s:5:"Wraps";s:21:"menu_item_description";s:36:"Meat cooked on a vertical rotisserie";s:14:"menu_item_icon";s:4:"3685";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"5.00";s:15:"menu_item_extra";s:0:"";}i:32;a:7:{s:15:"menu_item_title";s:18:"Chicken Tikka Wrap";s:15:"restaurant_menu";s:5:"Wraps";s:21:"menu_item_description";s:52:"Mix together the yoghurt tikka paste and lemon juice";s:14:"menu_item_icon";s:4:"3682";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.99";s:15:"menu_item_extra";s:0:"";}i:33;a:7:{s:15:"menu_item_title";s:24:"Chicken Piece on Its Own";s:15:"restaurant_menu";s:7:"Chicken";s:21:"menu_item_description";s:82:"Fried chicken is a dish consisting of chicken pieces usually from broiler chickens";s:14:"menu_item_icon";s:4:"3684";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"1.00";s:15:"menu_item_extra";s:0:"";}i:34;a:7:{s:15:"menu_item_title";s:23:"1 Piece of Chicken Meal";s:15:"restaurant_menu";s:7:"Chicken";s:21:"menu_item_description";s:61:"Salad topped reviewer Kellys expectations for a chicken salad";s:14:"menu_item_icon";s:4:"3692";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"2.50";s:15:"menu_item_extra";s:0:"";}i:35;a:7:{s:15:"menu_item_title";s:24:"2 Pieces of Chicken Meal";s:15:"restaurant_menu";s:7:"Chicken";s:21:"menu_item_description";s:51:"A delightful chicken dish with a little spicy kick.";s:14:"menu_item_icon";s:4:"3677";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.00";s:15:"menu_item_extra";s:0:"";}i:36;a:7:{s:15:"menu_item_title";s:15:"Popcorn Chicken";s:15:"restaurant_menu";s:7:"Chicken";s:21:"menu_item_description";s:65:"This is a wonderful Southern treat in which everyone will enjoy! ";s:14:"menu_item_icon";s:4:"3686";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:1:"3";s:15:"menu_item_extra";s:0:"";}i:37;a:7:{s:15:"menu_item_title";s:15:"Chicken Nuggets";s:15:"restaurant_menu";s:7:"Chicken";s:21:"menu_item_description";s:54:"These are really easy and taste great! Kids love them!";s:14:"menu_item_icon";s:4:"3685";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.70";s:15:"menu_item_extra";s:0:"";}i:38;a:7:{s:15:"menu_item_title";s:11:"Tuna Panini";s:15:"restaurant_menu";s:7:"Paninis";s:21:"menu_item_description";s:63:"These patties are great dipped in ketchup mustard or hot sauce.";s:14:"menu_item_icon";s:4:"3683";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.49";s:15:"menu_item_extra";s:0:"";}i:39;a:7:{s:15:"menu_item_title";s:16:"Vegetable Panini";s:15:"restaurant_menu";s:7:"Paninis";s:21:"menu_item_description";s:95:"This is a delicious sandwich which can be served for lunch or dinner. Paired with a green salad";s:14:"menu_item_icon";s:4:"3680";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.88";s:15:"menu_item_extra";s:0:"";}i:40;a:7:{s:15:"menu_item_title";s:29:"Jacket Potato with 2 Fillings";s:15:"restaurant_menu";s:15:"Jacket Potatoes";s:21:"menu_item_description";s:45:"Twice baked potatoes every kids favorite dish";s:14:"menu_item_icon";s:4:"3694";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"2.99";s:15:"menu_item_extra";s:0:"";}i:41;a:7:{s:15:"menu_item_title";s:14:"Lamb Chops (4)";s:15:"restaurant_menu";s:15:"Jacket Potatoes";s:21:"menu_item_description";s:71:"Tasty lamb chops are cooked on the stovetop with a tasty balsamic sauce";s:14:"menu_item_icon";s:4:"3694";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.50";s:15:"menu_item_extra";s:0:"";}i:42;a:7:{s:15:"menu_item_title";s:16:"Chicken Boti (8)";s:15:"restaurant_menu";s:15:"Jacket Potatoes";s:21:"menu_item_description";s:71:"Chicken cubes mildly flavored with cheddar cheese grilled to perfection";s:14:"menu_item_icon";s:4:"3699";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.00";s:15:"menu_item_extra";s:0:"";}i:43;a:7:{s:15:"menu_item_title";s:11:"Seekh Kebab";s:15:"restaurant_menu";s:15:"Jacket Potatoes";s:21:"menu_item_description";s:68:"Seekh kebab can also be served in a naan bread much like doner kebab";s:14:"menu_item_icon";s:4:"3698";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.99";s:15:"menu_item_extra";s:0:"";}i:44;a:7:{s:15:"menu_item_title";s:14:"Chicken Pakora";s:15:"restaurant_menu";s:8:"Starters";s:21:"menu_item_description";s:51:"A deliciously crunchy and satisfying Indian starter";s:14:"menu_item_icon";s:4:"3697";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"2.40";s:15:"menu_item_extra";s:0:"";}i:45;a:7:{s:15:"menu_item_title";s:13:"Crispy Samosa";s:15:"restaurant_menu";s:8:"Starters";s:21:"menu_item_description";s:82:"Samosa a crispy and spicy deep fried snack that has an crisp and flaky outer layer";s:14:"menu_item_icon";s:4:"3696";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"1.88";s:15:"menu_item_extra";s:0:"";}i:46;a:7:{s:15:"menu_item_title";s:14:"Mushroom Bhaji";s:15:"restaurant_menu";s:8:"Starters";s:21:"menu_item_description";s:72:"Serve with rice for a vegetarian dinner or with Naan bread for a starter";s:14:"menu_item_icon";s:4:"3695";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.67";s:15:"menu_item_extra";s:0:"";}i:47;a:7:{s:15:"menu_item_title";s:18:"Chicken Rogan Josh";s:15:"restaurant_menu";s:19:"Traditional Curries";s:21:"menu_item_description";s:90:"It consists of braised lamb chunks cooked with a gravy based on browned onions or shallots";s:14:"menu_item_icon";s:4:"3693";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"5.99";s:15:"menu_item_extra";s:0:"";}i:48;a:7:{s:15:"menu_item_title";s:16:"Keema Rogan Josh";s:15:"restaurant_menu";s:19:"Traditional Curries";s:21:"menu_item_description";s:90:"It consists of braised lamb chunks cooked with a gravy based on browned onions or shallots";s:14:"menu_item_icon";s:4:"3694";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"7.99";s:15:"menu_item_extra";s:0:"";}i:49;a:7:{s:15:"menu_item_title";s:14:"Prawn Cocktail";s:15:"restaurant_menu";s:19:"Traditional Curries";s:21:"menu_item_description";s:70:"A bed of crisp iceberg lettuce is topped with diced tomato and avocado";s:14:"menu_item_icon";s:4:"3692";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.99";s:15:"menu_item_extra";s:0:"";}i:50;a:7:{s:15:"menu_item_title";s:17:"King Prawn & Rice";s:15:"restaurant_menu";s:19:"Traditional Curries";s:21:"menu_item_description";s:72:"Pour the eggs into the empty side of the pan then scramble them stirring";s:14:"menu_item_icon";s:4:"3691";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"6.99";s:15:"menu_item_extra";s:0:"";}i:51;a:7:{s:15:"menu_item_title";s:11:"Fish Masala";s:15:"restaurant_menu";s:19:"Traditional Curries";s:21:"menu_item_description";s:119:"Heat oil in wok over moderate heat until hot but not smoking. Add mustard seeds and cook until they make popping sounds";s:14:"menu_item_icon";s:4:"3690";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"5.99";s:15:"menu_item_extra";s:0:"";}i:52;a:7:{s:15:"menu_item_title";s:7:"Chicken";s:15:"restaurant_menu";s:14:"Biryani Dishes";s:21:"menu_item_description";s:46:"Popular variations use chicken instead of goat";s:14:"menu_item_icon";s:4:"3689";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:1:"6";s:15:"menu_item_extra";s:0:"";}i:53;a:7:{s:15:"menu_item_title";s:5:"Keema";s:15:"restaurant_menu";s:14:"Biryani Dishes";s:21:"menu_item_description";s:53:"Made with mince meat and Basmati rice and some spices";s:14:"menu_item_icon";s:4:"3688";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"5.00";s:15:"menu_item_extra";s:0:"";}i:54;a:7:{s:15:"menu_item_title";s:5:"Mixed";s:15:"restaurant_menu";s:14:"Biryani Dishes";s:21:"menu_item_description";s:46:"Made mixed biryani with chicken prawn and fish";s:14:"menu_item_icon";s:4:"3687";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"6.00";s:15:"menu_item_extra";s:0:"";}i:55;a:7:{s:15:"menu_item_title";s:15:"Garlic Mushroom";s:15:"restaurant_menu";s:17:"Vegetarian Dishes";s:21:"menu_item_description";s:49:"Add mushrooms and toss with garlic butter to coat";s:14:"menu_item_icon";s:4:"3686";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"5.50";s:15:"menu_item_extra";s:0:"";}i:56;a:7:{s:15:"menu_item_title";s:13:"Bombay Potato";s:15:"restaurant_menu";s:17:"Vegetarian Dishes";s:21:"menu_item_description";s:66:"Blend together the ginger garlic and quartered tomato until smooth";s:14:"menu_item_icon";s:4:"3684";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"4.99";s:15:"menu_item_extra";s:0:"";}i:57;a:7:{s:15:"menu_item_title";s:13:"Mushroom Rice";s:15:"restaurant_menu";s:4:"Rice";s:21:"menu_item_description";s:97:"Melt butter in a saucepan over medium heat. Cook mushrooms garlic and green onion until mushrooms";s:14:"menu_item_icon";s:4:"3683";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"5.99";s:15:"menu_item_extra";s:0:"";}i:58;a:7:{s:15:"menu_item_title";s:14:"Egg Fried Rice";s:15:"restaurant_menu";s:4:"Rice";s:21:"menu_item_description";s:97:"Fried rice is a Chinese dish of steamed rice that has been stir fried in a wok and usually mixed.";s:14:"menu_item_icon";s:4:"3681";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.89";s:15:"menu_item_extra";s:0:"";}i:59;a:7:{s:15:"menu_item_title";s:11:"Boiled Rice";s:15:"restaurant_menu";s:4:"Rice";s:21:"menu_item_description";s:51:" Is rice that has been partially boiled in the husk";s:14:"menu_item_icon";s:4:"3680";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.99";s:15:"menu_item_extra";s:0:"";}i:60;a:7:{s:15:"menu_item_title";s:8:"Chapatti";s:15:"restaurant_menu";s:5:"Bread";s:21:"menu_item_description";s:78:"The Indus valley is known to be one of the ancestral lands of cultivated wheat";s:14:"menu_item_icon";s:4:"3679";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"3.00";s:15:"menu_item_extra";s:0:"";}i:61;a:7:{s:15:"menu_item_title";s:4:"Roti";s:15:"restaurant_menu";s:5:"Bread";s:21:"menu_item_description";s:90:"Roti is a flatbread originating from the South Asia made from stoneground wholemeal flour.";s:14:"menu_item_icon";s:4:"3683";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"1.00";s:15:"menu_item_extra";s:0:"";}i:62;a:7:{s:15:"menu_item_title";s:10:"Mint Sauce";s:15:"restaurant_menu";s:6:"Sauces";s:21:"menu_item_description";s:114:"Mint sauce is a sauce traditionally made from finely chopped peppermint (Mentha piperita) leaves soaked in vinegar";s:14:"menu_item_icon";s:4:"3678";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"1.00";s:15:"menu_item_extra";s:0:"";}i:63;a:7:{s:15:"menu_item_title";s:12:"Chilli Sauce";s:15:"restaurant_menu";s:6:"Sauces";s:21:"menu_item_description";s:125:"Chilli sauce is a type of hot sauce or chili sauce made from a paste of chili peppers distilled vinegar garlic sugar and salt";s:14:"menu_item_icon";s:4:"3677";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:4:"1.00";s:15:"menu_item_extra";s:0:"";}}

我正在使用原始 php 提取该数据,无需 WordPress,并且需要将 meta_value 转换为纯文本,而无需 a:64 u:0 或 s:37 只是纯信息。

a:64:{i:0;a:7:{s:15:"menu_item_title";s:37:"Chicken Tandoori Special 12" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:35:"Cheese tomatoes, and italian herbs.";s:14:"menu_item_icon";s:4:"3699";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"4.5";s:15:"menu_item_extra";a:1:{s:7:"heading";a:1:{i:0;s:0:"";}}}i:1;a:7:{s:15:"menu_item_title";s:38:"Chicken Tandoori Special  09" Deep Pan";s:15: 

最佳答案

a:64 是序列化符号。
a 代表数组。
64 代表 64 个数组元素。

您可以使用 PHP 的函数 unserialize() 将序列化字符串转换为 PHP 的数据类型。

要获得没有序列化符号的干净字符串,您可以使用 json_decode()。

所以你的代码看起来像

PHP

json_decode(unserialize('a:64:{i:0;a:7:{s:15:"menu_item_title";s:37:"Chicken Tandoori Special 12" Deep Pan";s:15:"restaurant_menu";s:7:"Calzone";s:21:"menu_item_description";s:35:"Cheese tomatoes, and italian herbs.";s:14:"menu_item_icon";s:4:"3699";s:15:"menu_item_nutri";s:0:"";s:15:"menu_item_price";s:3:"4.5";s:15:"menu_item_extra";a:1:{s:7:"heading";a:1:{i:0;s:0:"";}}}i:1;a:7:{s:15:"menu_item_title";s:38:"Chicken Tandoori Special  09" Deep Pan";s:15:'));

关于php - 将 Wordpress sql 值转换为纯文本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47472771/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com