This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require "connection.php"; | |
$data = json_decode(file_get_contents("php://input")); | |
$id = $data->id; | |
$name = $data->name; | |
$age = $data->age; | |
$phone = $data->phone; | |
$query = "CALL st_updateUser('$name', $age, '$phone', $id)"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require "connection.php"; | |
$data = json_decode(file_get_contents("php://input")); | |
$name = $data->name; | |
$age = $data->age; | |
$phone = $data->phone; | |
$query = "CALL st_insertUser('$name', $age, '$phone')"; | |
if(mysqli_query($con, $query)) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$con = mysqli_connect("localhost", "root", "", "api"); | |
if($con) { | |
// echo "Connection Established"; | |
} else { | |
die(); | |
} | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- phpMyAdmin SQL Dump | |
-- version 5.0.2 | |
-- https://www.phpmyadmin.net/ | |
-- | |
-- Host: 127.0.0.1 | |
-- Generation Time: Dec 10, 2020 at 09:46 PM | |
-- Server version: 10.4.14-MariaDB | |
-- PHP Version: 7.2.33 | |
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; |
NewerOlder