...

View Full Version : Help preg_match()



iamhatinh
07-28-2008, 07:34 PM
<asx version = "3.0">
<entry>
<title>Test 123 test</title>
<ref HREF="link" />
</entry>


My code:


preg_match('/<asx version = "3.0">\n\r\<entry>\n\r\<title>(.*?)<\/title>\n\r\<ref HREF="(.*?)" \/>\n\r\<\/entry>/',$content,$url);

It not work :eek:
Pls help :D

Fou-Lu
07-28-2008, 08:58 PM
Try adding a multiline flag (m) to you're pattern after the last / but before the closing '. If it still doesn't work, add a \t or \s* before the <title> and <href> lookups to account for the whitespace.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum