Beispiel #1
0
                $limit = $browse->get_offset();
                if ($limit > 0 && $value > 0) {
                    $total = $browse->get_total();
                    $pages = ceil($total / $limit);
                    if ($value <= $pages) {
                        $offset = ($value - 1) * $limit;
                        $browse->set_start($offset);
                    }
                }
                break;
        }
        ob_start();
        $browse->show_objects(null, $argument);
        $results[$browse->get_content_div()] = ob_get_clean();
        break;
    case 'get_share_links':
        $object_type = $_REQUEST['object_type'];
        $object_id = intval($_REQUEST['object_id']);
        if (Core::is_library_item($object_type) && $object_id > 0) {
            Share::display_ui_links($object_type, $object_id);
            exit;
        }
        break;
    default:
        $results['rfc3514'] = '0x1';
        break;
}
// switch on action;
$browse->store();
// We always do this
echo xoutput_from_array($results);