Re: html italic tag hinders search code

2009-02-10 Thread Jeff FW
Yes, that's what I was suggesting. Sorry for not being more clear. As for storing the field twice, unless you're planning to have huge amounts of records, you wouldn't really noticed any difference at all. Also, you can have the admin interface set to *not* display the stripped version, so your

Re: html italic tag hinders search code

2009-02-06 Thread May
Creating a duplicate field without tags looks like it might be the way to go, then. I just hate the redundancy of two fields of data. Thanks to both you and Jeff! May On Feb 6, 12:30 pm, Karen Tracey wrote: > On Fri, Feb 6, 2009 at 3:05 PM, May wrote: > > > I have data entry clerks typing th

Re: html italic tag hinders search code

2009-02-06 Thread Karen Tracey
On Fri, Feb 6, 2009 at 3:05 PM, May wrote: > > I have data entry clerks typing the data, so I cannot have them type > the titles twice. I'm quite sure Jeff wasn't suggesting having anyone type the titles in twice. Rather, when something with a title is saved, you have code (maybe in a save() o

Re: html italic tag hinders search code

2009-02-06 Thread May
Hello, I have data entry clerks typing the data, so I cannot have them type the titles twice. Is there a command where I could strip the tags out after the keywords are typed but before python goes to the database to search? This is the def: query = request.GET.get('q', '') if query:

Re: html italic tag hinders search code

2009-02-06 Thread Jeff FW
The issue has nothing to do with your templates--it has to do with your data, and how you're searching it. In the database, you have stored "Survival of Shigella". If you do a regular text search (field__contains, or similar) for "Survival of Shigella", you'll never get a match, because those st

html italic tag hinders search code

2009-02-06 Thread May
In the database I need to italics species names ex. Survival of Shigella In the search template I use the following: Search for Publications: When a user types in "Survival of Shigella" the search code finds no record, because I think the tags are hindering the search someho