Hello. I want to send some pings after post something to my blog. As you know wordpress use this method. I coded my own blog system and I want to send pings some web address.
For example I want to request this link. www.google.com/webmasters/tools/ping?sitemap=http://www.domain.com/sitemap.ashx
System.Net.NetworkInformation.Ping p = new System.Net.NetworkInformation.Ping();
System.Net.NetworkInformation.PingReply prep;
string url = "http://www.google.com/webmasters/tools/ping?sitemap=" + sitename + "/sitemap.ashx";
prep = p.Send(url);
if (prep.Status == System.Net.NetworkInformation.IPStatus.Success)
{
string address = prep.Address.ToString();
string time = prep.RoundtripTime.ToString();
}
else
{
string status = prep.Status.ToString();
}
This code is not working for me. Any other way?