<?php

////error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT);
error_reporting(1);
require 'viewer-webtier/pccConfig.php';
require 'viewer-webtier/utils.php';
//--------------------------------------------------------------------
//
//  For this sample, the location to look for source documents
//  specified only by name and the PCC Imaging Services (PCCIS) URL
//  are configured in PCC.config.
//
//--------------------------------------------------------------------
header('Content-Type: application/json');
PccConfig::parse("viewer-webtier/pcc.config");
$viewingSessionId = "";
$document = null;
$documentQueryParameter = stripslashes(rawurldecode($_FILES['file']['name']));
if (!empty($documentQueryParameter)) {
    $folder = PccConfig::getDocumentsPath();
    if (!is_writable($folder)) {
        header('HTTP/1.0 403 Forbidden');
        echo '<h1>403 Forbidden</h1>';
        return;
    }
    if (strstr($documentQueryParameter, "http://") || strstr($documentQueryParameter, "https://")) {
        $document = $documentQueryParameter;
    } else {
        $filenam = basename($documentQueryParameter);
        $filename = uniqid() . $filenam;
        $document = Utils::combine($folder, $filename);
<?php

////error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT);
error_reporting(0);
include '../pccConfig.php';
include '../utils.php';
//--------------------------------------------------------------------
//
//  For this sample, the location to look for source documents
//  specified only by name and the PCC Imaging Services (PCCIS) URL
//  are configured in PCC.config.
//
//--------------------------------------------------------------------
PccConfig::parse("../pcc.config");
$viewingSessionId = "";
$document = null;
$languageFilePath = "../language.json";
$predefinedSearchJSONPath = "../predefinedSearch.json";
$redactionReasonsJSONPath = "../redactionReason.json";
// Check for a language.json file, and load it if one exists. This is
// used by the HTML5 viewer to allow user customization of the various
// text strings it uses for buttons, tooltips and menu items.
$languageElements = "{}";
if (file_exists($languageFilePath)) {
    $languageElements = file_get_contents($languageFilePath);
}
// Check for a predefinedSearch.json file, and load it if one exists. This is
// used by the HTML5 viewer to allow user customization of the various
// predefined search options.
$predefinedSearch = "{}";
if (file_exists($predefinedSearchJSONPath)) {
Example #3
0
<?php

/**
 * ----------------------------------------------------------------------
 * <copyright file="pcc.php" company="Accusoft Corporation">
 * Copyright© 1996-2014 Accusoft Corporation.  All rights reserved.
 * </copyright>
 * ----------------------------------------------------------------------
 */
error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT);
set_time_limit(600);
include 'pccConfig.php';
include 'imagingServiceProxy.php';
include 'utils.php';
PccConfig::parse("pcc.config");
function getPage($matches)
{
    $page = new ImagingServiceProxy();
    $page->queryParameterWhiteList = array("DocumentID", "Scale", "ContentType", "Quality", "iv");
    $page->responseHeaderWhiteList = array("Content-Type", "Cache-Control", "Accusoft-Data-Encrypted", "Accusoft-Data-SK", "Accusoft-Status-Message", "Accusoft-Status-Number");
    echo $page->processRequest($matches);
}
function getPageTile($matches)
{
    $pageTile = new ImagingServiceProxy();
    $pageTile->queryParameterWhiteList = array("DocumentID", "Scale", "ContentType", "Quality", "iv");
    $pageTile->responseHeaderWhiteList = array("Content-Type", "Cache-Control", "Accusoft-Data-Encrypted", "Accusoft-Data-SK", "Accusoft-Status-Message", "Accusoft-Status-Number");
    echo $pageTile->processRequest($matches);
}
function getPageAttributes($matches)
{