这是可能的,在ASP.net中用C#编写一个套接字? 为例我可以在C#和asp.net中编写一个类似于此Perl代码的代码吗? :在ASP.net中使用C#编程的套接字编程
> use HTTP::Request::Common qw(POST);
> use LWP::UserAgent; $ua = new
> LWP::UserAgent(agent => 'Mozilla/5.0(Windows; U; Windows NT 5.1; en-US; rv:1.8.0.5)Gecko/20060719 Firefox/1.5.0.5');
> $ua -> timeout(20);
> my $req = POST 'http://Example.com/',
> [ login_username => 'mehdi' , login22 => '654321' , go => 'submit'];
> my $content = $ua->request($req);
请给我一个例子或将上面的代码转换为C#和asp.net。 在此先感谢。
这是可能的,但你会使用HTTP客户端,而不是原始套接字。 – 2010-11-15 17:12:13
http://www.c-sharpcorner.com/UploadFile/mahesh/WebRequestNResponseMDB12012005232323PM/WebRequestNResponseMDB.aspx – jocull 2010-11-15 17:13:49
Steven:是的,对不起,我对HTTP客户端=> Socket编程:d – Amra 2010-11-15 17:16:59