1

I have a php.ini file, similar to the following example:

;;;;;;;;;;;;;;;;;;;;
; Language Options ;
;;;;;;;;;;;;;;;;;;;;

; Enable the PHP scripting language engine under Apache.
; http://php.net/engine
engine = On

I need to search and select all lines that have no semicolon ";" as the first character

2
  • ^[^;].* would be a regex expression
    – Ron Trunk
    Apr 19, 2020 at 18:22
  • @RonTrunk that's a valid answer. Why don't you write up an answer? That way it can be marked as answered and earns you reputation.
    – LPChip
    Apr 19, 2020 at 19:50

1 Answer 1

1

You can use the regular expression (regex):

^[^;].*

to select lines without semicolons as the first character.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .