[]如何post发送json数据中包含&&特殊字符,怎么办?

下面用post方法请求一个数据方式如下:
var tj:any={"a":"123&&456", "b":"ccc"};
str="paramA="+JSON.stringify(tj);
//xhr.send("http:xxx.xxx.com","a=xxxx&b=xxx","post","text");
xhr.send("http:xxx.xxx.com",str,"post","text");

服务端解析的时候,paramA参数的值为:{"a":"123
剩下的被解析为另一个post变量了。
试了字符转义,没有用。
已邀请:

Laya_XS

赞同来自:

用base64转换就可以解决你的问题,找个相关的base64类就行了

要回复问题请先

商务合作
商务合作