Help talk:Searching/Regex
This is the talk page for discussing improvements to the Searching/Regex page. |
|
Backreference
[edit]Is there a way to use Backreference (e.g. (.)\1 )? Uziel302 (talk) 20:21, 27 July 2020 (UTC)
- @Uziel302: No, that's not supported;
\1
just matches a literal "1". For example, try this search. -- John of Reading (talk) 21:09, 27 July 2020 (UTC)- John of Reading, that's why I asked, and couldn't find on which level it is, mediawiki/elastic/lucene. Uziel302 (talk) 12:35, 28 July 2020 (UTC)
- โโ Me would like to see reference for the no-support status (it may be supported with a different syntax), rather than another non-working example, too. โMykhal (talk) 10:03, 5 October 2020 (UTC)
- @Mykhal: I'm not clear on the difference between mediawiki/elastic/lucene. Perhaps ask at WP:VPT to find someone who knows their way around the source code. I think that's the only possible reference for something not being supported. -- John of Reading (talk) 15:18, 5 October 2020 (UTC)
Dot .
not matching newline
[edit]Dot
[1]
Does it really? It doesn't seem to be doing it here. For instance, .
will match a newline, or any character in the targeted position\|-.*\|
doesn't match the beginning of table of rows. Am I doing it wrong? โ ๐๐ฎ๐๐ซ๐๐ฉ๐ข๐ซ๐๐ง๐ ๐ (talk) 03:58, 19 May 2021 (UTC)
Start and end of regexp for title
[edit]There is a text on the page: Regex experts should note that ^ does not mean "beginning of text" and $ does not mean "end of text." Searching from the beginning or end of a Wikipedia page is not generally useful.
However, searching from the beginning or end of a title is useful. Can you please implement these characters for the title? Maxim Masiutin (talk) 17:41, 14 December 2023 (UTC)
- I agree, they are indeed useful. By the way, in case you aren't aware, WP:PetScan supports the regex metacharacters ^ and $; see this discussion for examples. --JAAqqO (talk) 19:28, 14 December 2023 (UTC)