1

我进行手动关联的常用方法是设置左右边界,因为我在初始网页的 html 中找到它。但是,在 LoadRunner 中使用扩展日志记录时,我看到 JSESSIONID 是以这种方式从服务器返回的:

Action.c(4): Redirecting "http://xxx/xxx/" (redirection depth is 1)      [MsgId: MMSG-26694]

Action.c(4): To location "http://xxx/xxx/xxx/xxx"        [MsgId: MMSG-26693]

Action.c(4): t=3707ms: 384-byte response headers for "http://xxx/xxx/xxx/xxx" (RelFrameId=1,     Internal ID=3)

Action.c(4):     HTTP/1.1 302 Moved Temporarily\r\n

Action.c(4):     Server: Apache-Coyote/1.1\r\n

Action.c(4):     Set-Cookie: JSESSIONID=b6A10tdvDpwexLDVS4VKGHEX; Path=/xxx\r\n

Action.c(4):     Date: Thu, 17 Jan 2013 12:04:38 GMT\r\n

Action.c(4):     Expires: Thu, 01 Jan 1970 00:00:00 GMT\r\n

Action.c(4):     Pragma: no-cache\r\n

Action.c(4):     Cache-Control: no-cache, no-store\r\n

Action.c(4):     Location: http://xxx/xxx/xxx/xxx;jsessionid=b6A10td

Action.c(4):     vDpwexLDVS4VKGHEX?0\r\n

Action.c(4):     Content-Length: 0\r\n

Action.c(4):     \r\n

Action.c(4): Redirecting

我如何捕捉这个价值?因为它不在从服务器返回的 HTML 中?

BR马格努斯

4

1 回答 1

2

好的,解决了它使用这个:

web_reg_save_param("JSessionID", "LB=JSESSIONID=", "RB=;", LAST);
于 2013-01-17T12:36:32.590 回答