balzar Posted August 8, 2007 Share Posted August 8, 2007 I am implementing some very simple wiki rules therefore in a wiki content I need to find "=Heading1=", "==Heading 2==" and onwoards in order to replace it with <h1>,<h2> tags. The closes solution i have so far is '/={1}([^=].+?)={1}/' but it does not work properly. Please help!!! Quote Link to comment Share on other sites More sharing options...
effigy Posted August 8, 2007 Share Posted August 8, 2007 1. You don't need to specify {1} because the = is a--one--literal; this is assumed by default. 2. If you need to match multiple =s, use =+. 3. You don't need the .. The +? should apply to the character class. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.