Action()
{int i=0;//循环订票的游标变量char temp[255];//临时存储字符串变量int count=0;//存储循环关联数组长度变量char tempfly[255];//临时存储字符串变量web_url("WebTours", "URL=http://127.0.0.1:1080/WebTours/", "Resource=0", "RecContentType=text/html", "Referer=", "Snapshot=t1.inf", "Mode=HTTP", LAST);web_concurrent_start(NULL);web_url("header.html", "URL=http://127.0.0.1:1080/WebTours/header.html", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/", "Snapshot=t2.inf", "Mode=HTTP", LAST);web_url("welcome.pl", "URL=http://127.0.0.1:1080/WebTours/welcome.pl?signOff=true", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/", "Snapshot=t4.inf", "Mode=HTTP", LAST);web_concurrent_end(NULL);web_concurrent_start(NULL);web_url("hp_logo.png", "URL=http://127.0.0.1:1080/WebTours/images/hp_logo.png", "Resource=1", "RecContentType=image/png", "Referer=http://127.0.0.1:1080/WebTours/header.html", "Snapshot=t3.inf", LAST);web_url("webtours.png", "URL=http://127.0.0.1:1080/WebTours/images/webtours.png", "Resource=1", "RecContentType=image/png", "Referer=http://127.0.0.1:1080/WebTours/header.html", "Snapshot=t5.inf", LAST);web_concurrent_end(NULL);web_concurrent_start(NULL);web_url("home.html", "URL=http://127.0.0.1:1080/WebTours/home.html", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/welcome.pl?signOff=true", "Snapshot=t6.inf", "Mode=HTTP", LAST);web_reg_save_param("sessionuser","LB=",LAST);//获取用于session值的关联函数web_url("nav.pl", "URL=http://127.0.0.1:1080/WebTours/nav.pl?in=home", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/welcome.pl?signOff=true", "Snapshot=t7.inf", "Mode=HTTP", LAST);web_concurrent_end(NULL);web_concurrent_start(NULL);web_url("JSFormSubmit.js", "URL=http://127.0.0.1:1080/WebTours/JSFormSubmit.js", "Resource=1", "RecContentType=application/x-javascript", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?in=home", "Snapshot=t8.inf", LAST);web_url("mer_login.gif", "URL=http://127.0.0.1:1080/WebTours/images/mer_login.gif", "Resource=1", "RecContentType=image/gif", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?in=home", "Snapshot=t9.inf", LAST);web_concurrent_end(NULL);lr_start_transaction("login-0");lr_think_time(9);lr_error_message("sessionuser:%s",lr_eval_string("{sessionuser}"));//打印关联到的用户session值web_submit_data("login.pl", "Action=http://127.0.0.1:1080/WebTours/login.pl", "Method=POST", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?in=home", "Snapshot=t10.inf", "Mode=HTTP", ITEMDATA, "Name=userSession", "Value={sessionuser}", ENDITEM, "Name=username", "Value=test001", ENDITEM, "Name=password", "Value=123456", ENDITEM, "Name=JSFormSubmit", "Value=on", ENDITEM, "Name=login.x", "Value=64", ENDITEM, "Name=login.y", "Value=15", ENDITEM, LAST);web_concurrent_start(NULL);web_url("nav.pl_2", "URL=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=home", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/login.pl", "Snapshot=t11.inf", "Mode=HTTP", LAST);web_url("login.pl_2", "URL=http://127.0.0.1:1080/WebTours/login.pl?intro=true", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/login.pl", "Snapshot=t16.inf", "Mode=HTTP", LAST);web_concurrent_end(NULL);web_concurrent_start(NULL);web_url("flights.gif", "URL=http://127.0.0.1:1080/WebTours/images/flights.gif", "Resource=1", "RecContentType=image/gif", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=home", "Snapshot=t12.inf", LAST);web_url("signoff.gif", "URL=http://127.0.0.1:1080/WebTours/images/signoff.gif", "Resource=1", "RecContentType=image/gif", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=home", "Snapshot=t13.inf", LAST);web_url("itinerary.gif", "URL=http://127.0.0.1:1080/WebTours/images/itinerary.gif", "Resource=1", "RecContentType=image/gif", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=home", "Snapshot=t14.inf", LAST);web_url("in_home.gif", "URL=http://127.0.0.1:1080/WebTours/images/in_home.gif", "Resource=1", "RecContentType=image/gif", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=home", "Snapshot=t15.inf", LAST);web_concurrent_end(NULL);lr_end_transaction("login-0",LR_AUTO);lr_start_transaction("book-1");lr_think_time(11);web_url("Search Flights Button", "URL=http://127.0.0.1:1080/WebTours/welcome.pl?page=search", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=home", "Snapshot=t17.inf", "Mode=HTTP", LAST);web_concurrent_start(NULL);web_url("reservations.pl", "URL=http://127.0.0.1:1080/WebTours/reservations.pl?page=welcome", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/welcome.pl?page=search", "Snapshot=t18.inf", "Mode=HTTP", LAST);web_url("nav.pl_3", "URL=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=flights", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/welcome.pl?page=search", "Snapshot=t19.inf", "Mode=HTTP", LAST);web_concurrent_end(NULL);web_concurrent_start(NULL);web_url("home.gif", "URL=http://127.0.0.1:1080/WebTours/images/home.gif", "Resource=1", "RecContentType=image/gif", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=flights", "Snapshot=t20.inf", LAST);web_url("itinerary.gif_2", "URL=http://127.0.0.1:1080/WebTours/images/itinerary.gif", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=flights", "Mode=HTTP", LAST);web_url("signoff.gif_2", "URL=http://127.0.0.1:1080/WebTours/images/signoff.gif", "Resource=0", "RecContentType=text/html", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=flights", "Mode=HTTP", LAST);web_url("in_flights.gif", "URL=http://127.0.0.1:1080/WebTours/images/in_flights.gif", "Resource=1", "RecContentType=image/gif", "Referer=http://127.0.0.1:1080/WebTours/nav.pl?page=menu&in=flights", "Snapshot=t21.inf", LAST);web_concurrent_end(NULL);web_url("button_next.gif", "URL=http://127.0.0.1:1080/WebTours/images/button_next.gif", "Resource=1", "RecContentType=image/gif", "Referer=http://127.0.0.1:1080/WebTours/reservations.pl?page=welcome", "Snapshot=t22.inf", LAST);web_reg_save_param("flytype","LB=","ORD=ALL","Savelen=18",LAST);//关联取得出现的4张电子机票
// web_reg_save_param("seatPref","LB=
本文来自互联网用户投稿,文章观点仅代表作者本人,不代表本站立场,不承担相关法律责任。如若转载,请注明出处。 如若内容造成侵权/违法违规/事实不符,请点击【内容举报】进行投诉反馈!