Example #1
0
    $fieldCode = $clean['fieldcode'];
    $varables = array('path' => 'record', 'db' => $db, 'an' => $an, 'highlight' => $highlight, 'query' => $query, 'fieldCode' => $fieldCode, 'resultId' => $clean['resultId'], 'recordCount' => $clean['recordCount']);
} else {
    if ($clean['path'] == "PDF") {
        $db = $clean['db'];
        $an = $clean['an'];
        $varables = array('path' => 'PDF', 'db' => $db, 'an' => $an);
    } else {
        if ($clean['path'] == "HTML") {
            $db = $clean['db'];
            $an = $clean['an'];
            $highlight = $clean['highlight'];
            $query = $clean['query'];
            $fieldCode = $clean['fieldcode'];
            $varables = array('path' => 'HTML', 'db' => $db, 'an' => $an, 'highlight' => $highlight, 'resultId' => $clean['resultId'], 'recordCount' => $clean['recordCount'], 'query' => $query, 'fieldCode' => $fieldCode, 'c' => $c);
        } else {
            if ($clean['path'] == "results") {
                $query = $clean['query'];
                $fieldCode = $clean['fieldcode'];
                $varables = array('path' => 'results', 'query' => $query, 'fieldCode' => $fieldCode);
            } else {
                $varables = array('path' => 'index');
            }
        }
    }
}
$varables['fail'] = $fail;
ebsco_render('login.html', 'layout.html', $varables);
?>

<?php

include_once 'app/app.php';
$customparams = loadCustomParams($c, decryptCookie($_COOKIE['oauth_consumer_key']));
$variables = array('c' => $c, 'customparams' => $customparams);
ebsco_render('basic_search.html', 'layout.html', $variables);
Example #3
0
                $results = $api->apiSearch($params);
                if (isset($results['queryString'])) {
                    if (isset($results['queryString'])) {
                        if (isset($results['queryString'])) {
                            $backpath = $results['queryString'];
                        }
                    }
                } else {
                    $backpath = '';
                }
                //Cach the results for each session
                $_SESSION['results'] = $results;
            }
        }
    }
}
// Error
if (isset($results['error'])) {
    $error = $results['error'];
    $results = array();
} else {
    $error = null;
}
//save debug into session
if ($debug == 'y' || $debug == 'n') {
    $_SESSION['debug'] = $debug;
}
// Variables used in view
$variables = array('searchTerm' => $searchTerm, 'fieldCode' => urlencode($fieldCode), 'results' => $results, 'error' => $error, 'start' => $start, 'limit' => $limit, 'refineSearchUrl' => '', 'amount' => $amount, 'sortBy' => $sortBy, 'id' => 'results', 'Info' => $Info, 'backpath' => urlencode(urlencode($backpath)) ? urlencode(urlencode($backpath)) : '', 'debug' => isset($_SESSION['debug']) ? $_SESSION['debug'] : '', 'c' => $c, 'customparams' => $customparams);
ebsco_render('results.html', 'layout.html', $variables);
mysqli_close($c);
Example #4
0
<?php

if (!isset($_COOKIE['logged_in_cust_id'])) {
    die("You are unauthorized to view this page.  <a href='admin2.php'>Please login</a>.");
}
include 'app/app.php';
$variables = array('c' => $c);
ebsco_render('stats.html', 'layout.html', $variables);
    if (sizeof($listOfANs) > 0) {
        $query['query'] = implode(" OR ", $listOfANs);
        $searchTerm = $query;
        $fieldCode = '';
        $start = 1;
        $limit = 100;
        $sortBy = 'relevance';
        $amount = 'detailed';
        $mode = 'all';
        $expander = '';
        $limiter = '';
        $debug = '';
        $params = array('sort' => $sortBy, 'searchmode' => $mode, 'view' => $amount, 'includefacets' => 'n', 'resultsperpage' => $limit, 'pagenumber' => $start, 'highlight' => 'n', 'expander' => $expander);
        if (!is_array($limiter)) {
            $params['limiter'] = $limiter;
        }
        $params = array_merge($params, $query);
        $params = http_build_query($params);
        if (is_array($limiter)) {
            foreach ($limiter as $selectedLimiter) {
                $params .= "&limiter=" . urlencode($selectedLimiter);
            }
        }
        $results = $api->apiSearch($params);
    } else {
        $results = array();
    }
}
$variables = array('results' => $results, 'readingList' => $readingList, 'c' => $c, 'customparams' => $customparams, 'useCache' => $useCache);
ebsco_render('reading_list.html', 'layout.html', $variables);
<?php

include 'app/app.php';
$variables = array('c' => $c, 'username' => $username, 'password' => $password);
ebsco_render('manageaccess.html', 'layout.html', $variables);
<?php

include 'app/app.php';
$customparams = loadCustomParams($c, decryptCookie($_COOKIE['oauth_consumer_key']));
$variables = array('c' => $c, 'customparams' => $customparams);
ebsco_render('delete_list.html', 'layout.html', $variables);
Example #8
0
        $count = 0;
        while ($sql->fetch()) {
            $count++;
            $consumeridsArray['logged_in_consumerid'][$count] = $result;
        }
        if (!isset($consumeridsArray)) {
            $consumeridsArray = array();
        }
        setcookie('consumeridsArray', encryptCookie($consumeridsArray), $time, "/", $_SERVER['SERVER_NAME'], FALSE, TRUE);
        if ($c->more_results()) {
            $c->next_result();
        }
        $customparams = loadCustomParams($c, $key);
        $variables['consumeridsArray'] = $consumeridsArray;
        $variables['customparams'] = $customparams;
        ebsco_render('admin.html', 'layout.html', $variables);
    } else {
        if (isset($_COOKIE['forward_to_admin']) && decryptCookie($_COOKIE['forward_to_admin']) == "n") {
            if (isset($_POST['admin_key'])) {
                $clean = strip_tags_deep($_POST);
                setcookie('admin_key', encryptCookie($clean['admin_key']), $time, "/", $_SERVER['SERVER_NAME'], FALSE, TRUE);
                setcookie('admin_secret', encryptCookie($clean['admin_secret']), $time, "/", $_SERVER['SERVER_NAME'], FALSE, TRUE);
                $variables['admin_key'] = $clean['admin_key'];
                $variables['admin_secret'] = $clean['admin_secret'];
            }
            ebsco_render('sign_on.html', 'layout.html', $variables);
        } else {
            ebsco_render('sign_on.html', 'layout.html', $variables);
        }
    }
}
<?php

include 'app/app.php';
if (!isset($_COOKIE['currentListId'])) {
    echo "<div class='readingListLink'>Please open a reading list via your course website before using this feature.</div>";
    die;
}
$customparams = loadCustomParams($c, decryptCookie($_COOKIE['oauth_consumer_key']));
include 'rest/EBSCOAPI.php';
$api = new EBSCOAPI($c, $customparams);
$clean = strip_tags_deep($_REQUEST);
if (!isset($clean['db']) || !isset($clean['db'])) {
    echo "<div class='readingListLink'>Error: couldn't add this to the reading list.</div>";
    die;
} else {
    $db = $clean['db'];
    $an = $clean['an'];
}
$highlight = "";
$result = $api->apiRetrieve($an, $db, $highlight);
if (isset($result['error'])) {
    $error = $result['error'];
    echo "<div class='readingListLink'>Error: " . $result['error'] . "</div>";
    die;
} else {
    $error = null;
}
$variables = array('result' => $result, 'error' => $error, 'id' => 'record', 'c' => $c, 'customparams' => $customparams, 'an' => $an, 'db' => $db, 'currentListId' => decryptCookie($_COOKIE['currentListId']));
ebsco_render('add_to_list.html', 'layout.html', $variables);
<?php

include 'app/app.php';
$customparams = loadCustomParams($c, decryptCookie($_COOKIE['oauth_consumer_key']));
$variables = array('c' => $c, 'customparams' => $customparams);
ebsco_render('copy_list.html', 'layout.html', $variables);
<?php

include 'app/app.php';
$customparams = loadCustomParams($c, decryptCookie($_COOKIE['oauth_consumer_key']));
$variables = array('c' => $c, 'customparams' => $customparams);
ebsco_render('import_folder.html', 'layout.html', $variables);