Gamestudio Links
Zorro Links
Newest Posts
What are you working on?
by 3run. 09/19/19 09:42
Any chance of PBR materials with A8?
by Quad. 09/18/19 18:00
Sierra Chart Plugin
by AndrewAMD. 09/18/19 14:03
3d model editor
by karmacomposer. 09/18/19 13:18
Can MED export to FBX?
by karmacomposer. 09/18/19 13:07
I cannot get the A8 game engine to show anything
by karmacomposer. 09/18/19 12:38
Script, Start Trading Immediately
by jcl. 09/18/19 08:38
AUM Magazine
Latest Screens
The Space Between
Pogostuck: Rage With Your Friends
Worst Case Z
AckCon'18 - Lotter vs the World 2 - Preview Release
Who's Online Now
12 registered members (Ayumi, 3run, AndrewAMD, Quad, saulius, 20BN, kvm, MatPed, 3 invisible), 613 guests, and 7 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Dark_Light, oxygenjoe, web20tpo, tarekhazem, Juanjo
18290 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,246
Hiporope and its pain
txesmi Offline
Serious User
txesmi  Offline
Serious User

Joined: Jun 2007
Posts: 1,246
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,221
Germany / Essen
Uhrwerk Offline
Expert
Uhrwerk  Offline
Expert

Joined: Jan 2002
Posts: 4,221
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: 6
Mainz
NnamueN Offline
Newbie
NnamueN  Offline
Newbie

Joined: Feb 2010
Posts: 6
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,844
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,844
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: 6
Mainz
NnamueN Offline
Newbie
NnamueN  Offline
Newbie

Joined: Feb 2010
Posts: 6
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: 6
Mainz
NnamueN Offline
Newbie
NnamueN  Offline
Newbie

Joined: Feb 2010
Posts: 6
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: 6
Mainz
NnamueN Offline
Newbie
NnamueN  Offline
Newbie

Joined: Feb 2010
Posts: 6
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