pcre
PCRE matching whole words in a string
I\'m trying to run a regexp in ph开发者_运维百科p (preg_match_all) that matches certain whole words in a string, but problem is that it also matches words that contain only part of a tested word.[详细]
2023-04-10 16:25 分类:问答PHP slugify method without using preg_replace()
I am using following slugify method,in my local dev its working fine,but in my production server(CentOs) and the PCRE UTF8 supported but \"No Unicode properties support\".[详细]
2023-04-09 13:43 分类:问答How to use regular expression to extract bit in middle of a string
Using PHP PCRE regular expressions I want to extract the centre part of a string where the parts either si开发者_开发技巧de may or may not occur. I.e.[详细]
2023-04-08 10:49 分类:问答Regex for removing repeating numbers on different lines [duplicate]
This question already has an answer here: Reference - What does this regex mean? (1 answer) Closed 3 years ago.[详细]
2023-04-08 05:35 分类:问答regex - boundary characters (^ and $) versus escaped characters (\A and \Z)
What are the differences between, \\AMatch at only beginning 开发者_StackOverflowof string \\ZMatch at only end of string (or before newline at the end)[详细]
2023-04-05 22:18 分类:问答preg_replace, character escapes & accented characters. /u works on one server, but not another
I have the following code: preg_replace(\'/[^\\w-]/u\',\'.\',\'Bréánná MÓÚLÍN\'); Which on server A (PHP 5.3.5) returns:[详细]
2023-04-05 08:53 分类:问答Match a^n b^n c^n (e.g. "aaabbbccc") using regular expressions (PCRE)
It is a well known fact that modern regular expression implementations (most notably PCRE) have little in common with the original notion of regular grammars. For开发者_JAVA百科 example you can parse[详细]
2023-04-05 07:48 分类:问答Using PHP regex to parse XML
How can I use a regular expression to parse XML? Let\'s suppose we have the following: $string = \'<z>1a<z>2b</z>3c<z>4d</z>5e</z>\';[详细]
2023-04-05 03:11 分类:问答Problem with or in Regexp
I have this Regexp: /\\{%\\s([^else|endloop|endif][a-z0-9\\.\\|_]+)\\s%\\}/si I use this regexp in preg_replace.[详细]
2023-04-05 00:47 分类:问答Count subpatterns in PHP PCRE RegEx
I want to implement something like \"editor for regular expressions\". It is for power users of my PHP application. The problem is, I need something like \"reflection\" for the regular expression (to[详细]
2023-04-01 22:06 分类:问答