6, "d_location" => 3); if ($_SERVER[REQUEST_METHOD] == "POST") { error_log($_SERVER['REQUEST_URI']." POST = ". print_r($_POST, true) ); $sortCriteria->sortColumn = $columnMap[$_POST['orderOn']]; $sortCriteria->ascending =(($_POST['orderBy']=="ASC")?(1):(0)); $sortCriteria->filterPattern = $_POST['filterPattern']; $libraryGUID = $_POST['libraryGUID']; $mediaTypeCode = (int)$_POST['mediaTypeCode']; } else { error_log($_SERVER['REQUEST_URI']." GET = ". print_r($_GET, true) ); $sortCriteria->sortColumn = $columnMap['d_slotType']; $sortCriteria->ascending = 1; $sortCriteria->filterPattern = "*"; $libraryGUID = $_GET['libraryGUID']; $mediaTypeCode = (int)$_GET['mediaTypeCode']; } if( $libraryGUID != "0" ) $slots = get_media_destinations_by_type($user, $sortCriteria, $libraryGUID, $mediaTypeCode); else { error_log("Initalizing the slots array to None"); $slots = array(); } $numRows = count($slots); $numPages = ceil($numRows / ITEMS_PER_PAGE); $lowPageList = 1; $highPageList = min($numRows, ITEMS_PER_PAGE); $drives = get_all_drives($user, $sortCriteria); ?>