SA-MP Forums Archive
HTTP GET - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: HTTP GET (/showthread.php?tid=656138)



HTTP GET - djoudjou - 08.07.2018

Hello,

I want create an API who make a forum account when an user register on the server.

My script:

Код:
public RegisterAccount(playerid, mail[], password[])
{
	new
		request[550];

	format(request, sizeof(request), "publickey?=%s&privatekey=%s&username=%s&sampid=%d&email=%s&password_hash=%s", API_PUBLIC_KEY, API_PRIVATE_KEY, GetName(playerid), 0, mail, password);
	HTTP(playerid, HTTP_GET, API_LINK, request, "CreateAccount_HTTP");
	return 1;
}

forward CreateAccount_HTTP(index, response_code, data[]);
public CreateAccount_HTTP(index, response_code, data[])
{
	printf("index: %d | response_code: %d | data[]: %s", index, response_code, data);
}
What is wrong ? It doesn't work...


Re: HTTP GET - djoudjou - 08.07.2018

In logs, I have :

Код:
[13:29:00] [sampgdk:error] Too many callback arguments (at most 32 allowed)
[13:29:00] [sampgdk:error] Too many callback arguments (at most 32 allowed)
[13:29:00] [sampgdk:error] Too many callback arguments (at most 32 allowed)
[13:29:01] [sampgdk:error] Too many callback arguments (at most 32 allowed)
[13:29:01] [sampgdk:error] Too many callback arguments (at most 32 allowed)
[13:29:01] [sampgdk:error] Too many callback arguments (at most 32 allowed)



Re: HTTP GET - jlalt - 08.07.2018

Update your plugins, I think this error occurs when you have two plugins with different samp gdk version....