public function getContactById() { $person = new PersonPDO(); $this->nameDOB = $person->readById($this->personId); $address = new AddressPDO(); $this->address = $address->readAllByPersonId($this->personId); $phoneNumber = new PhoneNumberPDO(); $this->phoneNumber = $phoneNumber->readAllByPersonId($this->personId); $emailAddress = new EmailAddressPDO(); $this->emailAddress = $emailAddress->readAllByPersonId($this->personId); $image = new ImagePDO(); $this->avatar = $image->getAvatarImageByPersonId($this->personId); $this->image = $image->readAllByPersonId($this->personId); }
public function upload($cImage) { self::createImageFolder(); self::moveToImageFolderRenameCopy(); self::resizeFullSize(); self::resizeThumbNail(); $model = new ImagePDO(); $model->create($cImage); }
<?php require "controllers/LoginController.php"; require "models/Contact.php"; $image = new ImagePDO(); $personId = $image->getPersonIdByImageId($id); if ($personId === null) { header("Location: listcontacts.php"); } $image->setPreviousNextImageId($id); ob_start(); ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="css/bootstrap.min.css"> <link rel="stylesheet" href="css/styles.css"> <link rel="stylesheet" type="text/css" href="css/main.css"/> <link rel="stylesheet" href="//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css"> <script src="js/jquery-1.12.0.min.js"></script> <script src="//code.jquery.com/ui/1.11.4/jquery-ui.js"></script> <title>Picture</title> </head> <body> <?php include "includes/header.php"; ?> <div class="container" >