JumpBox

<< | Cookbook-V1 | >>

Note: The recipes here are for PmWiki versions 0.6 and 1.0 only. For PmWiki 2.0 recipes, see Cookbook.


Goal

Create a [[$Jump]] markup that provides a text box to quickly jump to another page, or conduct a search if the page doesn't exist.

Solution

Attach:jumpbox.php

Discussion

This recipe adds [[$Jump]] markup sequence that generates a text box where a user can enter the name of a page to navigate to (instead of having to use links or edit the browser URI). If the user enters the name of a page that doesn't exist, then a search is performed instead.

For example, entering a page name in the box below will jump directly to that page. Entering an invalid or nonexistent page name causes search results to be displayed instead.

$Jump?

See Also

  • Main.SearchWiki
  • SearchGroup
  • SearchBoxOnHeader

History

  • Created 25-Jan-2004 by <#>?

Comments & Bugs

There probably should be some sort of indication in the search results that the requested page was unavailable a list of pages containing the text string are being displayed instead.

Contributors

  • <#>?, based on suggestions by S. Leite

pmwiki-2.3.32 -- Last modified by {{}}?

from IP: 85.171.160.186 ip should be disabled by default for security reasons