HTTP ?
#1

Код:
new Testing = 5;
new string[128];
format(string, sizeof(string), "test=%i", Testing);
HTTP(playerid, HTTP_POST, "localhost/test/test.php", string, "MyHttpResponse");
When i start server at home it work and post data to php
but when i put it on host it not posting data to php file WHY
Reply
#2

I guess the second one, but not sure.
Reply
#3



bump
Reply
#4

I would also say Second one, seems it has the most correct format usage
Reply
#5

ok its work but now i have another problem

everting is working fine when i run server at home but when i put my gamemode on host HTTP function not post data why ?

home i use windows on host is linux this can be problem ?
Reply
#6

Do you have the .php file in your host?
Reply
#7

yes i have
Reply
#8

it's possible my gamehost to block http function to post data ?
Reply
#9

try replacing this:

PHP код:
HTTP(playeridHTTP_POST"localhost/test/test.php"string"MyHttpResponse"); 
into this:
PHP код:
HTTP(playeridHTTP_POST".../test/test.php"string"MyHttpResponse"); 
Maybe it works because Online hostings use ... to define server directory
Reply
#10

i am not posting data on same host where is my server i post it on another host

HTTP(playerid, HTTP_POST, "www.myhost.com/test/test.php", string, "MyHttpResponse");


it's possible my gamehost to block sa-mp http function to post data ?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)