hankknight
asked on
PHP/REGEX: Bullets if Line Starts with Dash
Using PHP and REGEX, how can I automatically convert dashes at the beginning of each line into bullets, providing there is exactly one space after the dash and the proceeding charactor is NOT a lowercase letter?
- Hello World
should become:
• Hello World
- 123 Testing
should become:
• 123 Testing
- this is a test
should not be changed.
Hello - World
should not be changed.
- Hello World
should become:
• Hello World
- 123 Testing
should become:
• 123 Testing
- this is a test
should not be changed.
Hello - World
should not be changed.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Open in new window