homepage Welcome to WebmasterWorld Guest from 54.167.179.48
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Pubcon Platinum Sponsor 2014
Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
Forum Library, Charter, Moderators: coopster & jatar k

PHP Server Side Scripting Forum

    
need to write a simple regex
need help
dopecoder

5+ Year Member



 
Msg#: 11614 posted 10:51 pm on Feb 1, 2006 (gmt 0)

i need to write a simple regex for php that would remove a signature.

it starts with '======Some text======'

and its followed by few lines of text with links.

i want to remove every thing starting from '======Some text======'

 

DrDoc

WebmasterWorld Senior Member drdoc us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 11614 posted 5:00 am on Feb 2, 2006 (gmt 0)

$string = preg_replace("/======Some text======.*$/is", "", $string);

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved