Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- include 'dbconnect.php';
- $user = '';
- if(isset($_POST['userId']) && !empty($_POST['userId']))
- {
- $user = $_POST['userId'];
- }
- $sql = "SELECT * FROM users WHERE userId = '$user' ";
- $query = mysqli_query($conn, $sql);
- if($query)
- {
- $data = mysqli_fetch_assoc($query);
- echo json_encode($data);
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement