The following content is obtained by begging for regular expression matching, and there is no result in the study for a long time. The html code is as follows: & lt; div & nbsp; class = "brandItem-info" & gt; & nbsp; & lt; div & nbsp; class = "bIi-brand & nbsp; j begged for regular expression matching to find the following content, and there was no result for a long time.
The html code is as follows:
Eva Ouxiu/Ihua o
Brand description:
Street, commuting, women's wear;
Total monthly sales: 5702 pieces
Representatives of fashion business lifestyle, suitable for handsome, elegant, and sexy urban women dressed in conference negotiations, casual parties, banquet parties.
Follow this brand
PHP regular expressions are required to match the content starting from the beginning to the end.
Thank you.
------ Best solution --------------------
preg_match('/(.*)<\/div>/is',$str,$mat);
print_r($mat[1]);
Ah?
------ Other solutions --------------------
Reference:
PHP code
Preg_match ('/(. *) <\/div>/is', $ str, $ mat );
Print_r ($ mat [1]);
Ah?
I can't try it because I forgot to tell you that the above code is in html and there is a lot of content later. Http://brand.tmall.com/categoryIndex.htm? IndustryId = 110 & categoryId = 50031407 & etgId = 91 & page = 1 get the brand in this address. Information
------ Other solutions --------------------
Reference:
Reference:
PHP code
Preg_match ('/(. *) <\/div>/is', $ str, $ mat );
Print_r ($ mat [1]);
Ah?
I can't try it because I forgot to tell you that the above code is in html and there is a lot of content later. Http://brand.tmall.com/categoryindex.htm .......
Regular answer:
Preg_match_all ('/(.*?) <\/Div>/ism ', $ content1, $ mat );
Print_r ($ mat );
Thanks to franzhong