Gamestudio Links
Zorro Links
Newest Posts
Zorro Trader GPT
by TipmyPip. 03/06/24 09:27
VSCode instead of SED
by 3run. 03/01/24 19:06
Deeplearning Script
by wolfi. 02/26/24 12:46
Sam Foster Sound | Experienced Game Composer for Hire
by titanicpiano14. 02/22/24 16:22
AssetAdd() vs. modern asset list?
by jcl. 02/21/24 15:01
How many still using A8
by Aku_Aku. 02/20/24 12:18
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (degenerate_762, TedMar), 519 guests, and 12 spiders.
Key: Admin, Global Mod, Mod
Newest Members
sakolin, rajesh7827, juergen_wue, NITRO_FOREVER, jack0roses
19043 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
http_post undeclared identifier #467542
08/10/17 22:51
08/10/17 22:51
Joined: Mar 2014
Posts: 359
CocaCola Offline OP
Senior Member
CocaCola  Offline OP
Senior Member

Joined: Mar 2014
Posts: 359
hello,

I'm trying the code from the manual, but I get the error
:http_post undeclared identifier ... E355

Code:
#include <acknex.h>
#include <default.c>
#include <acknet.h>
STRING* ip_str = "";

// start the script "ip.php" on a remote server, and return the caller's IP address
function main()
{
   var id = http_post("http://underhut.de/postEchtzeit/index.php",NULL);
   while (!http_status(id)) 
     wait(1);//wait for the server to reply
   if (http_status(id) == 1) { //transfer successful?
     http_result(id,ip_str);   //get the replied IP
     printf(_chr(ip_str));
  } else
     error("Error during transfer!");
  http_free(id); //always cleanup the httpid!
  sys_exit(NULL);
}


the index.php is:
Php Code:

<?php $ip ="$REMOTE_ADDR";echo "Your IP: $ip";?>


Last edited by CocaCola; 08/10/17 22:53.
Re: http_post undeclared identifier [Re: CocaCola] #467543
08/11/17 06:59
08/11/17 06:59
Joined: Jun 2007
Posts: 1,337
Hiporope and its pain
txesmi Offline
Serious User
txesmi  Offline
Serious User

Joined: Jun 2007
Posts: 1,337
Hiporope and its pain
Hi,
the http call is made by 'http_sendpost' instead of 'http_post'. It was wrong in previous manual versions but it is already corrected in the last version.

Salud!

Re: http_post undeclared identifier [Re: txesmi] #467544
08/11/17 09:25
08/11/17 09:25
Joined: Mar 2014
Posts: 359
CocaCola Offline OP
Senior Member
CocaCola  Offline OP
Senior Member

Joined: Mar 2014
Posts: 359
thnk you! where can I download the new version as help file, and can i update sed for infos?

I tryed 'http_sendpost' and get error http is only for pro version, but in the manual are the blue square icons for
Version:
P LC

how to read then?

Re: http_post undeclared identifier [Re: CocaCola] #467553
08/11/17 21:00
08/11/17 21:00
Joined: Jan 2002
Posts: 4,225
Germany / Essen
Uhrwerk Offline
Expert
Uhrwerk  Offline
Expert

Joined: Jan 2002
Posts: 4,225
Germany / Essen
P LC means that the feature is Pro Version exclusive and only supported in Lite-C, not in C-Script.


Always learn from history, to be sure you make the same mistakes again...
Re: http_post undeclared identifier [Re: Uhrwerk] #467554
08/11/17 21:47
08/11/17 21:47
Joined: Mar 2014
Posts: 359
CocaCola Offline OP
Senior Member
CocaCola  Offline OP
Senior Member

Joined: Mar 2014
Posts: 359
Thank You Uhrwerk

Re: http_post undeclared identifier [Re: Uhrwerk] #472787
05/23/18 13:26
05/23/18 13:26
Joined: Feb 2010
Posts: 7
Mainz
NnamueN Offline
Newbie
NnamueN  Offline
Newbie

Joined: Feb 2010
Posts: 7
Mainz
Hi,

I also get the error even though I have the Pro version
does anyone have an idea why that is?

cu Roman


So Long, and Thanks For All the Fish.
Es geht nicht darum im höchsten Level zu sein, sondern alle die vorherigen erlebt und verstanden zu haben !
Re: http_post undeclared identifier [Re: NnamueN] #472797
05/23/18 20:10
05/23/18 20:10
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
That command got renamed to http_sendpost(), for whatever reason.


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends
Re: http_post undeclared identifier [Re: Superku] #472879
05/27/18 21:20
05/27/18 21:20
Joined: Feb 2010
Posts: 7
Mainz
NnamueN Offline
Newbie
NnamueN  Offline
Newbie

Joined: Feb 2010
Posts: 7
Mainz
Danke für die Info :-) http_sendpost, wo hast du die infos hier ?

cu Roman


So Long, and Thanks For All the Fish.
Es geht nicht darum im höchsten Level zu sein, sondern alle die vorherigen erlebt und verstanden zu haben !
Re: http_post undeclared identifier [Re: NnamueN] #472880
05/27/18 21:30
05/27/18 21:30
Joined: Feb 2010
Posts: 7
Mainz
NnamueN Offline
Newbie
NnamueN  Offline
Newbie

Joined: Feb 2010
Posts: 7
Mainz
Originally Posted By: NnamueN
Danke für die Info :-) http_sendpost, wo hast du die infos hier ?

cu Roman

Vergiss wider meine Frage ich hätte auch alleine draufkommen sollen und einfach in Acknet.h Nachschauen, manchmal ist man blind wen die Lösung einem vor der nasse liegt, ich depp :-)

cu Roman

Last edited by NnamueN; 05/27/18 21:34.

So Long, and Thanks For All the Fish.
Es geht nicht darum im höchsten Level zu sein, sondern alle die vorherigen erlebt und verstanden zu haben !
Re: http_post undeclared identifier [Re: NnamueN] #472884
05/28/18 09:02
05/28/18 09:02
Joined: Feb 2010
Posts: 7
Mainz
NnamueN Offline
Newbie
NnamueN  Offline
Newbie

Joined: Feb 2010
Posts: 7
Mainz
Hi
I have problems with https (SSL / TLS) Transport Protocol

it is working
Code:
var id = http_sendpost("http://www.ng-arena.de/ip.php",NULL);



But here I do not get any connection (http_result/http_status)
Code:
var id = http_sendpost("https://www.ng-arena.de/ip.php",NULL);



how can I call an "https" page with http_sendpost ?

Is it possible "Hypertext Transfer Protocol Secure" to use with http_sendpost ?
If not, is there a different solution?

cu Roman
youtube.com/vufDummies - ng-arena.de

p.s.: @Superku, freue mich schon auf dein Spiel, verfolge das schon seit Jahren, hoffe es bald in steam kaufen zu können :-)


So Long, and Thanks For All the Fish.
Es geht nicht darum im höchsten Level zu sein, sondern alle die vorherigen erlebt und verstanden zu haben !
Page 1 of 2 1 2

Moderated by  HeelX, Spirit 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1