When it comes to Regex I am dumber than a door nail, so when making a Firefox extension I asked a friend for help and he gave me this:
if( doc.location.href.match(/(www\.google.*?[?&]q=[^&]+)/i) )
but the AMO editor rejected it saying it was too broad (for instance it would match http://uptime.netcraft.com/up/graph?site=www.google.com), can someone help me / give me a regex that matches the following (according to the editor it should match basically this) : http(s)://www.google.tld/q=*
So for example it should match
http or https (normal and secure) as well as any tld after Google (like .ru, .se, .fr, .in etc)
In other words it should only match Google search.
Thanks in advance for your help!
/Ryan
Try
The
(?:\.[a-z]{2,3}){1,2}is to match like.com.au,.co.uketc.