Hi all,
Successfully tested "CreateCommand" in B4a and corresponding thing in B4j. Working fine.
B4X:
Dim cmd As DBCommand = CreateCommand("get_data", Array(cell))
Now I want to use "PostString" instead of "CreateCommand" in B4a. Got sample coding in B4a, Need sample coding to receive "PostString" command and return json string from B4j.
<?php
$_id = isset( $_POST["id"] ) ? $_POST["id"] : null; // Check if id POST is set
$_var1 = isset( $_POST["variable1"] ) ? $_POST["variable1"] : null; // Check if variable1 POST is set
If (isset($_id))
{
//$id is set!
//Do something here
echo $_var1;
}else{
header("HTTP/1.0 400 Bad Request");
//exit('Not found');
}
?>
Now I want to use "PostString" instead of "CreateCommand" in B4a. Got sample coding in B4a, Need sample coding to receive "PostString" command and return json string from B4j.
This is the full source code for B4XQuiz server. SQL script to generate database in post #2 For B4XQuiz client app, please check: https://www.b4x.com/android/forum/threads/b4jquiz-desktop-app.124202/ Update It is now easier to create Web API Server using B4X Template Check...