Bilal Salas

Bilal Salas

  • NA
  • 21
  • 0

webproxy problem

Jun 13 2010 11:48 PM
Hi,what is the different between Webproxy and Iwebproxy??
I am in syrial but
and when I use this code:
                        HttpWebRequest myWebRequest=(HttpWebRequest)WebRequest.Create(url);
myWebRequest.Proxy=WebRequest.GetSystemWebProxy();
HttpWebResponse myWebResponse=(HttpWebResponse)myWebRequest.GetResponse();
Stream stream=myWebResponse.GetResponseStream();
StreamReader sreader=new StreamReader(stream);
StreamWriter write=new StreamWriter("/home/abulwleed/Desktop/empty.html");
write.WriteLine(sreader.ReadToEnd());
myWebResponse.Close();
write.Close();
sreader.Close();
whin I open the saved page It'll be google page but not out(in syrial) server
it's Deutschland google server it is as i used a proxy but as you see in the code i use the system proxy and it's default (ISP proxy)
it is not just for google happend .it is for all sites.
pleas report what is the problem..


another little quistion :
when i write this code:
string ipproxy="proxy.kalamoon.edu.sy";
int port=3128;
WebProxy proxy = new WebProxy(ipproxy,port);
Uri url=new Uri("http://www.google.com/");
HttpWebRequest myWebRequest=(HttpWebRequest)WebRequest.Create(url);
myWebRequest.Proxy=proxy;
it this the right code to change my software proxy??
and surf using other than my isp proxy?


thanx a lot