<?php

# @name: ops_image.php
# @version: 0.1
# @creation_date: 2021-09-24
# @license: The MIT License <https://opensource.org/licenses/MIT>
# @author: Simon Bowie <ad7588@coventry.ac.uk>
# @purpose: Display images from OPS API image service

include '../ops_api.php';

if(isset($_GET["doc_ref"])){

  $image_output = get_images($_GET["doc_ref"]);

  //Display the image in the browser
  header('Content-type: application/pdf');
  echo $image_output;
  
}

?>