doucheng2053 2017-07-27 19:11
浏览 315

将json字符串转换为unicode

The description is a bit more complicated than the title. I'm working with some Wordpress plugins and on form submit, I want to do some work with the entry. Problem is, this is what I get as entry:

["\u0634\u0646\u0628\u0647 \u06f2\u06f1 \u0645\u0631\u062f\u0627\u062f\u060c \u0633\u0627\u0639\u062a \u0646\u0627\u0645\u0634\u062e\u0635"]

After searching the web for a while I figured out that this is JSON encoding, do you know how can I use PHP to reform this into unicode? Note that the entry is a string and "\u0634" for example is not a character, but a string with the length of 6 characters.

  • 写回答

1条回答 默认 最新

  • dpwfh874876 2017-07-27 19:18
    关注

    With json_decode() you can transform this json string (which represents an array with a single item) into a regular PHP array.

    评论

报告相同问题?

悬赏问题

  • ¥30 vmware exsi重置后登不上
  • ¥15 易盾点选的cb参数怎么解啊
  • ¥15 MATLAB运行显示错误,如何解决?
  • ¥15 c++头文件不能识别CDialog
  • ¥15 Excel发现不可读取的内容
  • ¥15 关于#stm32#的问题:CANOpen的PDO同步传输问题
  • ¥20 yolov5自定义Prune报错,如何解决?
  • ¥15 电磁场的matlab仿真
  • ¥15 mars2d在vue3中的引入问题
  • ¥50 h5唤醒支付宝并跳转至向小荷包转账界面