CultivateLabs / storytime

Storytime is a Rails 4+ CMS and blogging engine, with a core focus on content. It is built and maintained by @cultivatelabs
MIT License
752 stars 81 forks source link

Excerpt strip_tags #161

Closed danielmag closed 9 years ago

danielmag commented 9 years ago

Sometimes when I create a new post I see that, in the excerpt things like quotes (") are changed to ". After some investigation I saw that this was due to strip_tags being called on the excerpt.

Is this the expected behaviour?

Thank you!

bcroesch commented 9 years ago

Not sure I entirely follow -- those both look the same to me? Or am I missing something there?

Strip tags is just trying to sanitize our content some since we sometimes get garbage in the post content (e.g. someone pastes something from word).

danielmag commented 9 years ago

Sorry, github corrected the quote... I meant to say that thing like quotes are changed to "

After some search i found that it is related to this bug in rails: https://github.com/rails/rails-html-sanitizer/issues/31

Seems like it was already fixed: https://github.com/rails/rails-html-sanitizer/pull/35 Will make it to rails 4.2.2

optimum-dulopin commented 8 years ago

i use rails 4.2.5.1 and there is still this bug