Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Reg
ular
Ex
pressions
101
Upgrade to Pro
Enterprise
Regular Expression
"
(?<elIf>#elif\((?<elIfContents>[^\)]+)\)(?<elIfResult>[\s\S]+?(?=#elif|#end)))
"
gi
Input 1
New
Note: the #end should be added to the result of the ifelse group in part 1 #elif(#C.Length >= 1.9m) Tall boi #elif(#C.Name == bob) Hi bob #end #elif(#C.Length >= 1.9m)Tall boi#elif(#C.Name == bob)Hi bob#end
Substitution
Note: the #end should be added to the result of the ifelse group in part 1 #elif(#C.Length >= 1.9m) Tall boi #elif(#C.Name == bob) Hi bob #end #elif(#C.Length >= 1.9m)Tall boi#elif(#C.Name == bob)Hi bob#end