1

I'm currently learning how to use web developer tools. So as a part of it I'm trying to find some multiple keywords at the search box which appears after pressing ctrl + F

enter image description here

My question is How can I apply multiple search filters at a time uisng find. Like If i want to find more than 2 keywords in a source what is the best way to do it.

I've tried using regular expressions like so(I'm pretty sure syntax is wrong)

'Keyword1' & 'Keyword2'

Also tried

'Keyword1' | 'Keyword2'

Also tried

'Keyword1' or 'Keyword2'

But No use. I'm I missing anything here? I know we can use regular expressions but I'm looking for syntax to search multiple keywords. I'm pretty sure I've once used it a while ago . I don't remember exact expression to do so..

3
  • the search does not have a RegEx function built in it or some kind, its not possible to search more than 1 word at a time, you can see if there are extentions to add to your chrome, but i bet there is nothing. Commented Feb 8, 2023 at 10:48
  • 1
    Does this answer your question? Is it possible to search with regular expressions within Chrome's developer console? Commented Feb 8, 2023 at 10:54
  • Hi @Zyfella Thanks for the suggestion...But That post only answers if we can use regular expressions or not...But I'm looking for expressions so that I can plug more than 2 keywords at a time Commented Feb 10, 2023 at 5:04

2 Answers 2

3
+50

Using regex search, you can do: ^(?=.*foo)(?=.*bar).*$.

Source: https://stackoverflow.com/a/37692545/6911703

Sign up to request clarification or add additional context in comments.

Comments

1

The syntax is

keyword1|keyword2|keyword3

without spaces and quotations

In my machine first I needed to turn off the regex feature before searching, and than turn it on again. o.w. it got stucked

1 Comment

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.