TIDHttp支持Session吗?

解决方案 »

  1.   

    需要伪造session,以get为例
            IdHttp1.Get(mURL1);
            mStr := IdHttp1.Response.CustomHeaders.Values['Set-Cookie'];
            if Pos(';',mStr)>0 then
                    Session_ID := LeftBStr(mStr,Pos(';',mStr)-1)
            else
                    Session_ID := mStr;        IdHttp1.Request.CustomHeaders.Add('Cookie:' + Session_ID);
            IdHttp1.Get(mURL2);希望对你有所帮助。
      

  2.   

    TIDHttp能取得Html网页中的文本么,就是只有问题,没有html标记?
      

  3.   

    可以取得html的全文,但需要自己分析提取一下。
      

  4.   

    erhan() 有实例吗
      按照那个方法还是登陆不上