U++ framework
Do not panic. Ask here before giving up.

Home » Community » Newbie corner » skylark with server and client
skylark with server and client [message #56048] Tue, 19 January 2021 05:25 Go to previous message
BetoValle is currently offline  BetoValle
Messages: 210
Registered: September 2020
Location: Brasil Valinhos SP
Experienced Member
Hi,

in the application client i run the code (after server)


CONSOLE_APP_MAIN
{
      String url = "http://localhost:8001/myapp/qualqueres";   
      request.Post("id", "1234"); //** < --
      request.PostData("1111111");
      request.POST();
      String content = request.Execute(); 
       
      Cout() << "return " << content ;
  
      SetExitCode( 0 );
}


in the server application i run the code


SKYLARK(q, "qualqueres:POST")
{
   //**  "id" ??  "1234" ??  <--

   String c = http.GetRequestContent();

   http << c;
}

struct MyApp : SkylarkApp {
   MyApp() {
   root = "myapp";
  }
};

CONSOLE_APP_MAIN
{
   MyApp().Run();	
}



in the application client return the result "1111111".

my question:

in this adaptation I did how to make the parameter "id" and its value "1234"
passed by the client application, be read (evaluated) on the server and returned
to the client application?

(ie how do I read the parameters on the server, passed by the client, without manipulating
the traditional html?)

thanks





 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Skylark app - create pdf and donwload it
Next Topic: Cross Compiling?
Goto Forum:
  


Current Time: Sat Nov 14 07:53:29 GMT+1 2026

Total time taken to generate the page: 0.00531 seconds