You'll need to remove the HTML *before* excerpting... perhaps add another
method to your model:
def content_clean
content.remove_html_somehow
end
And then instead of calling (as an example) object.excerpts.content, call
object.excerpts.content_clean.
--
Pat
On 11/01/2010, at 2:00 AM, anrake wrote:
> Is it possible to have the excerpter code ignore all html when using
> excerpts? I used some regex to remove html in the view before
> displaying it on the page but the problem I'm having is that the
> excerpter cuts some html in the middle of a tag so this partial tag
> displays on screen and can sometimes affect other code downstream.
> --
> You received this message because you are subscribed to the Google Groups
> "Thinking Sphinx" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/thinking-sphinx?hl=en.
>
>
--
You received this message because you are subscribed to the Google Groups
"Thinking Sphinx" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/thinking-sphinx?hl=en.