branch setzen

This commit is contained in:
2022-12-18 18:58:54 +01:00
parent 87c4224271
commit bac04885b0
6 changed files with 64 additions and 26 deletions

View File

@ -13,22 +13,22 @@ require __DIR__.'/classes/lib.php';
$db_connection = new Database();
$conn = $db_connection->dbConnection();
//$data = json_decode(file_get_contents("php://input"));
$data = json_decode(
'{
"email": "a@q.q",
"password": "qwertzui"
}'
);
$data = json_decode(file_get_contents("php://input"));
// $data = json_decode(
// '{
// "email": "a@q.q",
// "password": "qwertzui"
// }'
// );
$returnData = new CMsg(0);
// IF REQUEST METHOD IS NOT EQUAL TO POST
// if($_SERVER["REQUEST_METHOD"] != "POST")
// {
// $returnData = new CMsg(0,404,'Page Not Found!');
// echo $returnData->jsonarray();
// return;
// }
//IF REQUEST METHOD IS NOT EQUAL TO POST
if($_SERVER["REQUEST_METHOD"] != "POST")
{
$returnData = new CMsg(0,404,'Page Not Found! REQUEST_METHOD');
echo $returnData->jsonarray();
return;
}
// CHECKING EMPTY FIELDS
if(