On Thu, 2011-04-21 at 16:35 -0700, Adam Katz wrote: > Broken apart from previous thread to prevent confusion. > > On 04/21/2011 04:18 PM, dar...@chaosreigns.com wrote:
> > I wonder if it would be useful to generalize this as: > > > > rawbody LOCAL_8X_TAGS /(?:<[^>]*>[\s\r\n]{0,4}){8}/mi Rawbody. Matches on plain text, too. And given the "zero or more" nature of the quantifiers, it does match '<>' repeated 8 times. Salt with space as you see fit. I seem to recall such things occasionally being used in text plain mail as some sort of fancy [1] delimiter in sigs... :/ [1] An euphemism for ugly. -- char *t="\10pse\0r\0dtu\0.@ghno\x4e\xc8\x79\xf4\xab\x51\x8a\x10\xf4\xf4\xc4"; main(){ char h,m=h=*t++,*x=t+2*h,c,i,l=*x,s=0; for (i=0;i<l;i++){ i%8? c<<=1: (c=*++x); c&128 && (s+=h); if (!(h>>=1)||!t[s+h]){ putchar(t[s]);h=m;s=0; }}}