
#/search
URL to the navigation or anywhere on the site. Beyond that, it’s also possible to implement search directly into a theme using a data attribute.
Implementing Search in themes
The quickest way is to use the{{search}}
helper to output a button with a search icon. See the helper docs for more details.
Alternatively, add the data-ghost-search
data attribute to any element in the theme. Here’s an example from the default theme Casper:
Cmd/Ctrl + K
.
Technical details
- Taxonomies for tags and authors must be present for search results to include tags and authors
- The post title and excerpt are used to search post content from the most recent 10,000 posts. (Excerpts are excluded for member-only posts)