HTTP Put Request

yomomma

Пользователь
Регистрация
17.02.2013
Сообщения
53
Благодарностей
2
Баллы
8
I want to use the Put request to ping urls I have created. I want to put this request in:

http://pingomatic.com/ping/?title={-Variable.title-}&{-Variable.domain-}

Am I putting the above in URL in the Put box, and what do I put in the Referrer?

Also, what goes in the Data box?
 

Nick

Client
Регистрация
22.07.2014
Сообщения
1 963
Благодарностей
796
Баллы
113

yomomma

Пользователь
Регистрация
17.02.2013
Сообщения
53
Благодарностей
2
Баллы
8

Nick

Client
Регистрация
22.07.2014
Сообщения
1 963
Благодарностей
796
Баллы
113
Sorry, I was wrong. I sent you a link to the service but it only tells you YOUR address, so just ignore me.
 

BAZAg

Client
Регистрация
08.11.2015
Сообщения
1 760
Благодарностей
2 398
Баллы
113
I want to use the Put request to ping urls I have created. I want to put this request in:
http://pingomatic.com/ping/?title={-Variable.title-}&{-Variable.domain-}
Am I putting the above in URL in the Put box, and what do I put in the Referrer?
Also, what goes in the Data box?
PUT
C#:
string title = "google";
string domain = "google.com";

var param = new List<string[]>();
    param.Add(new[]{"title", title});
    param.Add(new[]{"blogurl", domain});
string[] headers = new[]{ "Referer: http://pingomatic.com/" };
string url = string.Format(@"http://pingomatic.com/ping/?{0}",string.Join("&",param.Select(x=>string.Join("=",x))));

string put = ZennoPoster.HTTP.Request(
  method: ZennoLab.InterfacesLibrary.Enums.Http.HttpMethod.PUT,
  url: url,
  content: string.Empty,
  contentPostingType: string.Empty,
  proxy: string.Empty,
  Encoding: "UTF-8",
  respType: ZennoLab.InterfacesLibrary.Enums.Http.ResponceType.HeaderAndBody,
  Timeout: 30000,
  Cookies: string.Empty,
  UserAgent: project.Profile.UserAgent,
  UseRedirect: true,
  MaxRedirectCount: 3,
  AdditionalHeaders: headers,
  DownloadPath: null,
  UseOriginalUrl: true,
  throwExceptionOnError: true,
  cookieContainer: project.Profile.CookieContainer
);
return put;
GET
C#:
string title = "google";
string domain = "google.com";

var param = new List<string[]>();
    param.Add(new[]{"title", title});
    param.Add(new[]{"blogurl", domain});
string[] headers = new[]{ "Referer: http://pingomatic.com/" };
string url = string.Format(@"http://pingomatic.com/ping/?{0}",string.Join("&",param.Select(x=>string.Join("=",x))));

string get= ZennoPoster.HTTP.Request(
  method: ZennoLab.InterfacesLibrary.Enums.Http.HttpMethod.GET,
  url: url,
  content: string.Empty,
  contentPostingType: string.Empty,
  proxy: string.Empty,
  Encoding: "UTF-8",
  respType: ZennoLab.InterfacesLibrary.Enums.Http.ResponceType.HeaderAndBody,
  Timeout: 30000,
  Cookies: string.Empty,
  UserAgent: project.Profile.UserAgent,
  UseRedirect: true,
  MaxRedirectCount: 3,
  AdditionalHeaders: headers,
  DownloadPath: null,
  UseOriginalUrl: true,
  throwExceptionOnError: true,
  cookieContainer: project.Profile.CookieContainer
);
return get;
 
  • Спасибо
Реакции: myndeswx и Nick

yomomma

Пользователь
Регистрация
17.02.2013
Сообщения
53
Благодарностей
2
Баллы
8
thank you sir
 

myndeswx

Client
Регистрация
15.05.2017
Сообщения
402
Благодарностей
90
Баллы
28
There is a new action just for that, not GET/POST, just HTTP request, there you can select from many options-

93027
 

Кто просматривает тему: (Всего: 1, Пользователи: 0, Гости: 1)