Re: Regex for unnatural language

2006-08-03 Thread Dr.Ruud
Rob Dixon schreef: > I thought the group might like this one. > > I want a regex to check whether a string contains a sequence of > non-space characters with /both/ word and non-word characters in it > (\w and \W). > > So > >'Rob' >'SHREWSBURY' >'SY3 8BH' >'Mike & Dave' > > all pas

Regex for unnatural language

2006-08-03 Thread Rob Dixon
Hi. I thought the group might like this one. I want a regex to check whether a string contains a sequence of non-space characters with /both/ word and non-word characters in it (\w and \W). So 'Rob' 'SHREWSBURY' 'SY3 8BH' 'Mike & Dave' all pass, but 'http://www.site.com/' 'Rob&Da