[H-GEN] Help with REs
Peter Arnold
arnoldpj at optusnet.com.au
Fri Sep 19 01:10:46 EDT 2003
[ Humbug *General* list - semi-serious discussions about Humbug and ]
[ Unix-related topics. Posts from non-subscribed addresses will vanish. ]
[ NOTE: This message was held for moderator approval. The most common ]
[ reason for this is because it has been sent from an address which is ]
[ not subscribed to the list or the approved posting list. You may like ]
[ to check that your address is properly subscribed - see ]
[ majordomo at lists.humbug.org.au for info. ]
I'm trying to include a Regular Expression javascript in my proxy.pac file
that filters various contraband from (particularly https:) webmail sites
but I'm strugling somwhat.
I'd like to filter any (eg) .exe .doc .com .pif files based on their
appearance in the url 1) intermediatly or 2) at the end.
The best I can do is:
1) var contraband = /\.(exe|doc|com|pif)/i;
2) var contraband = /\.(exe|doc|com|pif)$/i;
This is later run in against the url to return 0 or 1
The above dosn't seem to be working (it's rather hard to check) so I'd
appreciate ideas, alternatives on the RE's above.
Cheers
Peter Arnold
--
* This is list (humbug) general handled by majordomo at lists.humbug.org.au .
* Postings to this list are only accepted from subscribed addresses of
* lists 'general' or 'general-post'. See http://www.humbug.org.au/
More information about the General
mailing list