Search content, in a page and get the field back?

Hello guys,

i want to search a string in the whole content of a specified page. Is it possible to get the field back where the string is saved?

Thanks,
Benni

The default search function only returns a collection of pages, so the answer is no. You would have to create your own search method to achieve that.

Okay, thanks a lot :slight_smile:

Depending on your use case, you could let the standard search function return the results collection. And then for each result, search for the string in all fields and return an array of fields with that search term.