Django-Haystack with Solr: Searching by page description meta tags

151 views Asked by At

I've been digging around and can't seem to find a way to create a search index for the page description meta tags using Haystack and Solr. Does anyone have experience with this, or any tips?

I have looked at the page model in cms, but can't figure out how to pull the meta tag information for use in the search index.

I am hoping to include this information so that when users search on the site, they will find relevant pages based on what they entered. I thought maybe it would be built in, but so far no luck locating that. Any help would be much appreciated.

1

There are 1 answers

0
Tipster On BEST ANSWER

Found the solution. Turns out the information I was looking for is in the Title model, NOT the page model. The Title model allows you to access all the page title, meta tags, menu titles, etc. So I just created a search index based off of that model and it works like a charm!

See here for the Title model:

CMS Github