- Where Developers Learn, Share, & Build Careers


If I have mentioned the data in my php variable, how do I get from "any" to "wish" from centains I can copy.

Data example:

If you have any question about Macmillan you have to love to hear from you < / P>

Thanks for the help.

Kind regards, reel

You can try:

  $ string = ' If you have any questions about Macmillan then we would like to hear from you. '; Preg_match ('/ (any) (. *?) (Will be) /', $ string, $ match); Match $ [0]; // Any questions about Macmillan we will match more than one result, if present:   

edit 1

  preg_match_all ('/ (any) (. *?) (Will be) /', $ string, $ matches); Foreign currency ($ values ​​as $ 0 [0]) 'echo': '$ value' & lt; Br / & gt; ';    

Comments

Popular posts from this blog

Python SQLAlchemy:AttributeError: Neither 'Column' object nor 'Comparator' object has an attribute 'schema' -

java - How not to audit a join table and related entities using Hibernate Envers? -

mongodb - CakePHP paginator ignoring order, but only for certain values -