Hi i’m trying to find all occurences of ‘<?’ in my php code. I use eclipse for this, and i tried to search for the folowing pattern: “<\?^[p]” in the hope this would return me all <? occrences, but not the <?php ones..
What’s wrong about the regex? I thought I had figured out regular expressions, but it seams like i still have a long way to go 🙁
I’m not familiar with Eclipse’s regular expression language but I’d imagine you want this:
The difference is:
[^p]means any character apart fromp^[p]means the start of a new line followed by ap.But you should check the manual for Eclipse to find out the exact regular expression syntax that Eclipse uses.