I have a regex which is matching urls which don't have quotes (double or single) at the end and have & (ampersand) in the url.
The regex i made
([^'` "\n]+)\.([^ \n]+)&([^ "`'\n]+)(?!["'])
but it's just not taking the last word and matching the url
https://regex101.com/r/vpmqZH/1
Take the example of picture above
google.com/cool?cool1=yes&cool2=no&cool3=no"
the url should not match as it have " in the end
but it's just not matching 'o' and matching the remaining url.
All I wanted to do is if this double quote is present in the end then just don't match the whole url.