1. 程式人生 > >loadrunner11 響應報文中文轉碼

loadrunner11 響應報文中文轉碼

//響應中文轉碼,開始
    web_reg_save_param("transcoding",  
        "LB=",  
        "RB=",   
        "Search=All",  
        LAST);

web_custom_request("web_custom_request",
        "URL=",
        "Method=POST",
        "Resource=0",
        "RecContentType=application/xml",
        "Mode=HTTP",
        "EncType=application/xml;charset=utf-8",
        "Body=“
        LAST);

//響應中文亂碼解決,結束
    lr_convert_string_encoding(lr_eval_string("{transcoding}"), "UTF-8","gb2312","Success");
    lr_output_message(lr_eval_string("{Success}"));