Regular Expression. come and help. Solution-php Tutorial

Source: Internet
Author: User
Regular Expression. come and help .. Relnofollow & gt; & lt; font & nbsp; & gt; & nbsp; 178th Painting & lt; font & gt; & lt; a & gt; & lt; span & gt; (Updated on: & nbsp; 2013-06-01 & nbsp; 22:06) & lt; span & gt; & nbsp; & lt; h3 & gt; & Regular. come and help ..


Rel = "nofollow">
178th painting (updated on:
)


Expected update time:No update notice




Style = "font-weight: 400" target = "_ blank">
As Wu Wang said, there is no family or near branch in the home region. Even the old man is the only parent. he has no elders on his head and no peers on his side. Who will talk to him in the face of the family affair like this?
Even though
......





Regular expression, get,
================================
178th flower paintings
======================================

==================================
As Wu Wang said, there is no family or near branch in the home region. Even the old man is the only parent. he has no elders on his head and no peers on his side. Who will talk to him in the face of the family affair like this?
Even though
======================================

As soon as a newline occurs, I cannot do it. Dizzy.

Share :? 178th painting (Updated :? 2013-06-01? 22: 06) <... 'data-pics = ''>


------ Solution --------------------
$ Reh = "/\. * \ <\/a \>;

If (preg_macth ($ reg, $ str, $ arr )){
Return true;
} Else {
Return false
}

Print_r ($ arr );

Try
------ Solution --------------------
 $ Str = 'Rel = "nofollow">
178th painting (updated on:
)


Expected update time:No update notice




Style = "font-weight: 400" target = "_ blank">
As Wu Wang said, there is no family or near branch in the home region. Even the old man is the only parent. he has no elders on his head and no peers on his side. Who will talk to him in the face of the family affair like this?
Even though
......


';

Preg_match ('/(.*?) <\/Font> .*? \ (Updated on .*? (\ D {4}-\ d {2}-\ d {2} \ s * \ d {2}: \ d {2 }).*?

.*? (.*?) <\/A> <\/p>/S', $ str, $ matches );
Var_dump ($ matches );



Be patient. it's not disgusting.

$ Matches [1] $ matches [2] $ matches [3] of the matches array is what you want.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.