I am using a regular expression to extract the image ID from the wordpress img tag, but if the img tags are continuous without sandwiching anything, it will be the longest match.
I was wondering if I should use?, But it didn't work out, and I hope I can borrow my wisdom.
Regular expression: //i Target: Expected results: 38, 36
Answer # 1
This kind of thing should be processed properly in the DOM
Answer # 2
Is it like this?
<? php preg_match_all ( '/ wp-image-(\ d +) /', ' ', $matches, PREG_PATTERN_ORDER ); print_r ($matches ); ?> Output result Array (  =>38  =>36 )
- php - i want to make a regular expression for the following rules
- i want to extract a hashtag from a python regular expression string
- how to extract only the character string with a specific character from the (comma) separated character string with a regular ex
- php - i want to use a regular expression but i don't know the time format
- i want to extract a url with a regular expression from a specific email that came to gmail
- php - [laravel 6] regular expression validation "|" handling
- php - about regular expression of preg_match
- php - i want to know how to write a regular expression for a symbol when preg_matching
- it's a php regular expression "negative lookahead", but why doesn't it work without a slash in front of it?
- php - what is the best delimiter when writing a url as a regular expression?
- why can't i get the results i expected from a c ++ regular expression full-width?
- character replacement with c # regular expression
- those who are familiar with php regular expressions
- php - unable to implement primality test expression
- regular expressions - the regular expression cannot be deciphered
- python - do not match only when the previous is "_" in the regular expression
- python - you may need to restart the kernel to use updated packages error
- php - coincheck api authentication doesn't work
- php - i would like to introduce the coincheck api so that i can make payments with bitcoin on my ec site
- [php] i want to get account information using coincheck api
- the emulator process for avd pixel_2_api_29 was killed occurred when the android studio emulator was started, so i would like to
- i want to call a child component method from a parent in vuejs
- python 3x - typeerror: 'method' object is not subscriptable
- dart - flutter: the instance member'stars' can't be accessed in an initializer error
- xcode - pod install [!] no `podfile 'found in the project directory