Lr手写脚本,返回信息的中文乱码的解决方法

1、Tools->Recording Options->Advanced->勾选Support charset UTF-8
2、Run-time Settings->Browser->Browser Emulation->Change,将language置为中文
3、web_add_auto_header("Accept-Language","zh-cn");
4、web_add_header("Content-Type","text/html;charset=UTF-8");
5、lr_convert_string_encoding(lr_eval_string("{rtn}"),LR_ENC_SYSTEM_LOCALE,LR_ENC_UTF8,"newRtn");
6、找default.cfg中,在[WEB]中添加UTF8InputOutput=1

猜你喜欢

转载自www.cnblogs.com/tudouxifan/p/8949660.html
今日推荐