weixin_33747129 2016-07-26 17:17 采纳率: 0%
浏览 330

获取formData附加的数据

I have a new FormData then added caption as key.

var formData = new FormData();
formData.append('caption','abc');

How do I get abc from it? I tried using .get but it's not supported in mobile chrome.

formData.get('caption'); // this will not work by default in chrome. 

Is there anywhere I can get caption value?

  • 写回答

1条回答 默认 最新

  • ℙℕℤℝ 2016-07-26 17:44
    关注

    By default Chome does not support the .get() method, you can enable that functionality by activating an flag.

    Chrome default support for method append.

    Methods which chrome does't support in default behavior : delete, get, getAll, has, and set.

    For activating flags in Chrome you can go to the following link:

    chrome://flags/#enable-experimental-webkit-features

    评论

报告相同问题?