Regex not within <script> tags -


this question has answer here:

need regex. i'd match within given string of html matches pattern \*[a-z0-9\_]+\* not fall in between <script> start , end tags. know has lookarounds, haven't clue how there.

using regex lookaround. can use:

(?!<script>)\*[a-z0-9\_]+\*(?!</script>) 

that match regex if not preceded , postceded script

enter image description here


Comments

Popular posts from this blog

google api - Incomplete response from Gmail API threads.list -

Installing Android SQLite Asset Helper -

Qt Creator - Searching files with Locator including folder -