HttpWebRequest not sending UserAgent

前端 未结 1 500
余生分开走
余生分开走 2021-01-20 01:44

I\'m new to looking at the whole Web side of .net, and I\'ve run into a slight issue.

I\'m trying to do a HttpWebRequest as below:

String uri = \"h         


        
1条回答
  •  忘掉有多难
    2021-01-20 02:22

    I don't think that you are looking at the correct Fiddler line. What you have shown is a CONNECT verb, not GET. The UserAgent should be properly set using the request.UserAgent property. Another way to debug the request is to configure network tracing at your application level which I personally prefer compared to Fiddler:

    
        
            
                
                    
                        
                    
                
            
            
                
            
            
                
            
            
        
    
    

    0 讨论(0)
提交回复
热议问题