Processing HTTP headers, formatting output

Source: Internet
Author: User
Tags button type

function Insertstr (str1,n,str2) {if(str1.length<N) {                returnstr1+str2; }Else{S1= Str1.substring (0, N); S2=str1.substring (n,str1.length); returns1+str2+S2; }} function Searchd (key1,mod_rest) {varLOC (Key1); if(loc==-1){                returnmod_rest; }            Else{                varMOD_RESTD = Insertstr (Mod_rest,loc,"\ n"); returnmod_restd; }} function Displayresult () {//print post and get            varTestVal = document.getElementById ("Mytextarea"). Value; varPost_get = Testval.split (" ",3); //alert (typeof post_get);            varRAW1 = post_get[0]+" "+post_get[1]+" "+post_get[2]; //The remainder is delimited with ":"//var rest = Testval.split (":", 5); //alert (typeof row1); //post_get.tostring ();Rest = Testval.replace (RAW1,""); //alert (rest);T= Searchd (/accept:/, rest); //alert (t);T1 = Searchd (/accept-encoding:/, T); T2= Searchd (/host:/, T1); T3= Searchd (/accept-charset:/, T2); T4= Searchd (/cookie:/, T3); T5= Searchd (/connection:/, T4); T6= Searchd (/cache-control:/, T5); T7= Searchd (/user-agent:/, T6); T8= Searchd (/pragma:/, T7); T9= Searchd (/acunetix-aspect:/, T8); T10= Searchd (/acunetix-aspect-password:/, T9); T11= Searchd (/acunetix-aspect-queries:/, T10); T12= Searchd (/content-length:/, T11); T13= Searchd (/content-type:/, T12); T14= Searchd (/accept-language:/, t13); T15= Searchd (/accept-ranges:/, t14); T16= Searchd (/authorization:/, t15); T17= Searchd (/date:/, t16); T18= Searchd (/expect:/, t17); T19= Searchd (/from:/, t18); T20= Searchd (/if-match:/, t19); T21= Searchd (/if-modified-since:/, T20); T22= Searchd (/max-forwards:/, t21); T23= Searchd (/proxy-authorization:/, t22); T24= Searchd (/range:/, T23); T25= Searchd (/warning:/, T24); T26= Searchd (/referer:/, T25); //alert (t26);document.getElementById ('Myexparea'). value=raw1+T26; }        </script> "Mytextarea"Name="Testt"cols=" the"Rows=" -">POST/maneinfo/login.asp http/1.1Pragma:no-cache Cache-control:no-cache referer: content-type:application/x-www-form-urlencoded acunetix-aspect:enabled acunetix-aspect-password:082119f75623eb7abd7bf357698ff66c Acunetix-aspect-queries:filelist;aspectalerts Cookies: ASPSESSIONIDSSATAQRD=AOGJBOEBGCGIFPCFHEDNOCNH connection:keep-alive Accept-encoding:gzip, Deflate user-agent:mozilla/5.0 (Windows NT 6.1; WOW64) applewebkit/537.36 (khtml, like Gecko) chrome/28.0.1500.63 safari/537.36 Accept: */* picnum=3943&pwhidden=& Amp;saveuser=&secex=&username=</textarea> <textarea id="Myexparea"Name="Expio"cols=" the"Rows=" -"> </textarea> <br> <button type="Button"onclick="Displayresult ()">alert value of text area</button> </body>

Processing HTTP headers, formatting output

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.