On Wed, Jun 22, 2011 at 15:24, Cal Leeming [Simplicity Media Ltd]
<cal.leem...@simplicitymedialtd.co.uk> wrote:
> We have actually just implemented this on one of our other sites still in
> development. The problem with keyword highlighting is you have to be careful
> not to enter into infinite loops, by ensuring you only match keywords
> outside of existing HTML tags. Normally I'd just say "figure it out for
> yourself", but this particular task took me about 4-5 hours to figure out,
> and was eventually solved by someone elses regex on google, so it's only
> fair I share :)
> Here is the code we have used (works 100% of the time so far) - this is
> quickly modified cut and paste, so you may need to tinker with it to make it
> work.

Thanks Cal. Real nice of you to share. As Tim also mentioned, the
solution is simple, but I figured there had to be some caveats with
the regex.
I'm really interested in your new project and would definitively watch
your webcast (ref. your other topic)

Again, thanks. Have a nice day.

-- 
With Regards, Herman Schistad

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to