Ah, how can I write two regular expressions into a regular expression? thank you! This post was last edited by cluonani from 2013-05-1314: 40: 09. this is the content to be matched & lt; td & nbsp; class = "LightRowHead" & gt; Prima Ah, how do I write to merge two regular expressions into one? thank you!
This post was last edited by cluonani at 14:40:09. this is the content to be matched.
Primary Color:
Multi-Color
Multi Pack Indicator:
No
Battery Type:
Does Not Contain a Battery
How can I combine this regular expression into one?
$a = preg_match_all('/LightRowHead.*?>(.*?):.*?LightRow.*?>(.*?)$a = preg_match_all('/DarkRowHead.*?>(.*?):.*?DarkRow.*?>(.*?)
This is not the case.
$a = preg_match_all('/[LightRowHead|DarkRowHead].*?>(.*?):.*?[LightRow|DarkRow].*?>(.*?)
Could someone tell me: Primary? Color: Multi-Color
------ Solution --------------------
(Xx
------ Solution --------------------
Yy)
------ Solution --------------------
It is changed to a single character when enclosed in square brackets. it must be enclosed in parentheses.
$ A = preg_match_all ('/(LightRowHead
------ Solution --------------------
DarkRowHead). *?> (.*?) :.*? (LightRow
------ Solution --------------------
DarkRow). *?> (.*?)If you don't want to add a forward reference, you can write it.
$ A = preg_match_all ('/(? : LightRowHead
------ Solution --------------------
DarkRowHead). *?> (.*?) :.*? (? : LightRow
------ Solution --------------------
DarkRow). *?> (.*?)
If you need to be paired, you can write.
$ A = preg_match_all ('/(LightRow
------ Solution --------------------
DarkRow) Head. *?> (.*?) :.*? \ 1. *?> (.*?)