ted_chou12 Posted November 17, 2008 Share Posted November 17, 2008 This (.*?) does not match with newline but I wish to also include the new line in the matched string: <start>this string contains a newline<end> What should I replace (.*?) with? Thanks, Ted. Link to comment https://forums.phpfreaks.com/topic/133082-solved-match-with-new-line-in-the-matched-string/ Share on other sites More sharing options...
ddrudik Posted November 17, 2008 Share Posted November 17, 2008 the s modifier is used for this: http://us3.php.net/manual/en/reference.pcre.pattern.modifiers.php Link to comment https://forums.phpfreaks.com/topic/133082-solved-match-with-new-line-in-the-matched-string/#findComment-692093 Share on other sites More sharing options...
ted_chou12 Posted November 17, 2008 Author Share Posted November 17, 2008 thanksĀ Link to comment https://forums.phpfreaks.com/topic/133082-solved-match-with-new-line-in-the-matched-string/#findComment-692099 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.