---
title: "Search"
manual: "Kitodo.Presentation"
version: "dev-demo"
source: "Demo/Search.rst"
rendered: "2026-09-27T16:21:24+00:00"
---

# Search {#demo-search}

> [!WARNING]
> **Caution**
>
> The search page and its Solr emulator exist only on the demo
>
> branch, not on `kitodo/main`.

The demo branch adds a **search** page (`dlf_search`) that works **without a
real Apache Solr server**. The extension talks to Solr through Solarium over
plain HTTP, so the demo ships a minimal Solr HTTP emulation that implements
just enough of the Solr JSON API for the read-only demo plugins
(`dlf_search`, `dlf_listview`, `dlf_collection`, `dlf_statistics`) to
work.

## How it works {#how-it-works}

-   The emulator (`Build/Demo/assets/solr-emulator.php`) is included from
    the demo's static data router (`Build/Demo/assets/data-router.php`).
    Any request under the `/solr/` prefix is answered with a Solr-style
    JSON response; anything else falls through to static file serving.
-   It implements the endpoints the extension uses: the core status probe
    (`/admin/cores?action=STATUS`, which the Solr constructor uses to
    decide the core is "ready"), the select / search requests
    (`/<core>/select`) and the update endpoint
    (`/<core>/update`) that the real indexer pushes documents to.
-   The documents to search over are the local sample documents; they are
    "indexed" by the regular indexer into the emulator's in-memory JSON catalog.

## The page {#the-page}

The `/search` page renders the `dlf_search` form and the results.
Clicking a result opens the document in the single-document viewer on the root
page. The Solr core record and the extension's Solr connection are pointed at
the local data server running the emulator, so no external Solr is contacted.
