Context:
Handeling PHP 2-3 codes I have to replace short tag "<?
" by "<?php
".
In order to find them I wanted to use the VS code find in folder feature to find all occurrence of it.
Question:
What is the correct syntax for contains <?
not followed by php
?
I've read the visual studio documentation here and tried in regex101. It seems to be valid in PCRE and ECMA. I must be missing something, because in Visual Studio Code it doesn't work.
"Regex parse error".
Regex:
<\?(?!php)
Input:
<?php
<?
<?PHP
Output:
<?