Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
help center: Rewrite /help/search-for-messages.
Alya Abbottec74416e5de6
diff --git a/templates/zerver/help/include/sidebar_index.md b/templates/zerver/help/include/sidebar_index.mdindex 761be8bcd4e..6f2eb83b312 100755--- a/templates/zerver/help/include/sidebar_index.md+++ b/templates/zerver/help/include/sidebar_index.md@@ -86,7 +86,7 @@* [View and browse images](/help/view-and-browse-images)* [View messages sent by a user](/help/view-messages-sent-by-a-user)* [Link to a message or conversation](/help/link-to-a-message-or-conversation)-* [Advanced search](/help/search-for-messages)+* [Searching for messages](/help/search-for-messages)* [View message Markdown source](/help/view-the-markdown-source-of-a-message)* [View when message was sent](/help/view-the-exact-time-a-message-was-sent)* [View a message's edit history](/help/view-a-messages-edit-history)diff --git a/templates/zerver/help/search-for-messages.md b/templates/zerver/help/search-for-messages.mdindex 0199ab92391..eda6da73f64 100644--- a/templates/zerver/help/search-for-messages.md+++ b/templates/zerver/help/search-for-messages.md@@ -1,104 +1,150 @@# Searching for messages-Zulip has a powerful search engine under its hood. Search for messages using-the search bar at the top of the app.+Zulip has a powerful search engine under its hood. You can search for messages using+keywords and filters via the search bar at the top of the app.-## Example+## Keyword search-* `stream:design has:link -is:starred new logo`+Zulip lets you search messages and topics by keyword. For example:-Searches for messages in `#design` that have a link, that you haven't-starred, and that contain the words `new` and `logo`.+* `new logo`: Search for messages with both `new` and `logo` in the message or+ its topic.+* `"new logo"`: Search for messages with the phrase "`new logo`" in the message+ or its topic.-The permalink for that search (web only) will look something like-this:+Some details to keep in mind:-`https://your-zulip-url/#narrow/stream/123-design/has/link/-is/starred/search/new.20logo`.+- Keywords are case-insensitive, so `wave` will also match `Wave`.+- Zulip will find messages containing similar keywords (keywords with the same+ stem), so, e.g., `wave` will match `waves` and `waving`.+- Zulip search ignores very common words like `a`, `the`, and about 100 others.+- [Emoji](/help/emoji-and-emoticons) in messages (but not [emoji+ reactions](/help/emoji-reactions)) are included in searches, so if you search+ for `octopus`, your results will include messages with the `:octopus:` emoji (+ <img src="/static/generated/emoji/images-google-64/1f419.png" alt="octopus"+ class="emoji-small"/>).-## List of operators+## Search filters-As you start typing, Zulip will suggest possible operator completions.-Operators can be used with keywords, or on their own. For example,+Zulip also offers a wide array of search filters, which can be used on their+own, or in combination with keywords. For example:-* `stream:design logo` will search for the word `logo` within `#design`-* `stream:design` will navigate to `#design`+* `stream:design`: Navigate to **#design**.+* `stream:design logo`: Search for the keyword `logo` within **#design**.+* `stream:design has:image new logo`: Search for messages in **#design** that+ include an image and contain the keywords `new` and `logo`. The keywords can+ appear in the message itself or its topic.-Here is the **full list of search operators**.+!!! tip ""-* `stream:design`: Search within the stream `#design`.-* `stream:design topic:emoji+picker`: Search within the topic `emoji picker`.+ As you start typing into the search box, Zulip will suggest search filters+ you can use.++### Search by location++Sometimes you know approximately where the message you are looking for was sent.+Zulip offers the following filters based on the location of the message.++* `stream:design`: Search within the stream **#design**.+* `stream:design topic:new+logo`: Search within the topic "new logo" in+ **#design**.* `is:private`: Search all your private messages.-* `pm-with:[email protected]`: Search 1-on-1 private messages between you and Ada.-* `pm-with:[email protected],[email protected]`: Search group private messages- between you, Bob, and Ada.-* `group-pm-with:[email protected]`: Search all group private message- conversations that include you and Ada, as well as any other users.-* `sender:[email protected]`: Search messages sent by Ada.-* `sender:me`: [Search messages you've sent](/help/view-messages-sent-by-a-user#view-messages-youve-sent).-* `near:12345`: Show messages around the message with ID `12345`.-* `id:12345`: Show only message `12345`.-* `is:alerted`: See [alert words](/help/pm-mention-alert-notifications#alert-words).-* `is:mentioned`: See [mentions](/help/mention-a-user-or-group).-* `is:starred`: See [starred messages](/help/star-a-message).-* `is:resolved`: Search messages in [resolved topics](/help/resolve-a-topic).-* `-is:resolved`: Search messages in [unresolved topics](/help/resolve-a-topic).-* `is:unread`-* `has:link`-* `has:image`-* `has:attachment`+* `pm-with:Bo Lin`: Search 1-on-1 private messages between you and Bo.+* `pm-with:Bo Lin, Elena García`: Search group private messages+ between you, Bo, and Elena.+* `group-pm-with:Bo Lin`: Search all group private message+ conversations that include you and Bo, as well as any other users.* `streams:public`: Search the history of all [public- streams](/help/change-the-privacy-of-a-stream) in the organization,- including streams you are not subscribed to.+ streams](/help/change-the-privacy-of-a-stream) in the organization, including+ streams you are not subscribed to; see details+ [below](#searching-shared-history).-### Excluding messages+### Search by sender-Zulip's search operators can be negated, to exclude messages matching-the rule. For example, `stream:design -is:resolved -has:image` will-match all messages that don't contain an image and were sent to-unresolved topics in the `#design` stream.+* `sender:Elena García`: Search messages sent by Elena.+* `sender:me`: Search messages you've sent.-## Searching shared history+!!! tip ""-Zulip's [stream permissions](/help/stream-permissions) model allows-access to the full history of public streams and [private streams with-shared history](/help/stream-permissions), including messages sent-before you joined the stream (or organization) or those sent to public-streams you are not subscribed to.+ You can also access all messages someone has sent [via their **user+ card**](/help/view-messages-sent-by-a-user).-By default, Zulip searches messages in your history, i.e. the-messages you actually received. This avoids cluttering search results-with irrelevant messages from public streams you're not interested in.+### Search for attachments or links++* `has:link`: Search messages that contain URLs.+* `has:attachment`: Search messages that contain an [uploaded+ file](/help/share-and-upload-files).+* `has:image`: Search messages that contain an uploaded image or link to an image.++!!! tip ""++ You can also [view](/help/manage-your-uploaded-files) all the files you have uploaded+ or [browse](/help/view-and-browse-images) all the images in the current view.++### Search your important messages-If you'd like to instead search the organization's shared history, any-query using the `stream:` or `streams:` operators will search all-messages that you have access to in the selected stream(s). For-example:+* `is:alerted`: Search messages that contain your [alert+ words](/help/pm-mention-alert-notifications#alert-words).+* `is:mentioned`: Search messages where you were+ [mentioned](/help/mention-a-user-or-group).+* `is:starred`: Search your [starred messages](/help/star-a-message).-* `streams:public keyword` searches for `keyword` in all public- streams in the organization.-* `streams:public sender:[email protected]` searches for all messages- sent by the user to any public stream.+### Search by message status-## Words and phrases+* `is:resolved`: Search messages in [resolved topics](/help/resolve-a-topic).+* `-is:resolved`: Search messages in [unresolved topics](/help/resolve-a-topic).+* `is:unread`: Search your unread messages.++### Search by message ID++Each message in Zulip has a unique ID, which is used for [linking to a specific+message](/help/link-to-a-message-or-conversation#link-to-zulip-from-anywhere).+You can use the search bar to navigate to a message by its ID.++* `near:12345`: Show messages around the message with ID `12345`.+* `id:12345`: Show only message `12345`.+* `stream:design near:1` Show the oldest messages in the **#design** stream.-Most searches consist of a list of operators followed by a list of keywords.+### Exclude filters-* `new logo`: Search for messages with both `new` and `logo`.-* `"new logo"`: Search for messages with the phrase `"new logo"`.+All of Zulip's search filters can be negated to **exclude** messages matching+the specified rule. For example:++- `stream:design -is:resolved -has:image`: Search messages in [unresolved+ topics](/help/resolve-a-topic) in the **#design** stream that don't contain+ images.++## Searching shared history++Zulip's [stream permissions](/help/stream-permissions) model allows access to+the full history of public streams and private streams with shared history,+including messages sent before you joined the stream (or organization), or those+sent to public streams you are not subscribed to.++By default, Zulip searches messages in your history, i.e., the+messages you actually received. This avoids cluttering search results+with irrelevant messages from public streams you're not interested in.-Zulip does some basic stemming, so `wave` will match `waves` and-`waving`. Keywords are case-insensitive, so `wave` will also match `Wave`.+If you'd like to instead search the organization's shared history, any query+using the `stream:` or `streams:` filters will search all messages that you have+access to in the selected stream(s). For example:-Emoji are included in searches, so if you search for `octopus` it will-include messages with-<img src="/static/generated/emoji/images-google-64/1f419.png" alt="octopus"-class="emoji-small"/>.+* `streams:public logo`: Search for `logo` in all public streams in the+ organization.+* `streams:public sender:Elena García`: Search for all messages sent by+ Elena to any public stream.+* `stream:design logo`: Search for the word `logo` in all messages sent to+ **#design**, regardless of whether you were subscribed at the time the message+ was sent.+## Linking to search results-Note that Zulip ignores common words like `a`, `the`, and about 100-others. A quirk in Zulip's current implementation means that if all of your-keywords are ignored, we'll return 0 search results.+When you search Zulip, the URL shown in the address bar of the Zulip web app is a+permanent link to your search. You can share this link with others, and they+will see *their own* search results for your query.## Related articles* [Configure multi-language search](/help/configure-multi-language-search)+* [Link to a message or+ conversation](/help/link-to-a-message-or-conversation#link-to-zulip-from-anywhere)