Update fullbody.php

This commit is contained in:
Mario 2023-05-22 13:20:34 +03:00 committed by GitHub
parent 7e0bf54cba
commit f1904071b8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 2 deletions

View File

@ -1,10 +1,11 @@
<?php
// this file is entirely made by nolanwhy, no skid pls
// mario here again with his comments
require_once '../../../core/classes.php';
require_once '../../../core/config.php';
$id = (int)$_GET["userId"] ?? 0;
$id = (int)$_GET["userId"] ?? 1; // get the id if its none then 1
$stmt = $con->prepare("SELECT * FROM users WHERE id = :id");
$stmt->bindParam(':id',$id,PDO::PARAM_INT);
$stmt->bindParam(':id',$id,PDO::PARAM_INT); // teh bind param
$stmt->execute();
$ruser = $stmt->fetch();
if(!$ruser) {
@ -51,3 +52,4 @@ if(empty($ruser["thumbnail"])) {
} else {
echo base64_decode($ruser["thumbnail"]);
}
?>