public static function DeletePhoto($id, $dbname)
{
$db = Db::getConnection();
$sql = 'DELETE FROM :table WHERE id = :id';
$result = $db->prepare($sql);
$result->bindParam(':id', $id, PDO::PARAM_INT);
$result->bindParam(':table', $dbname, PDO::PARAM_STR);
$result->execute();
}