# Sanitize within helpers

**URL:** <https://www.ruby-forum.com/t/sanitize-within-helpers/163745>\
**Category:** Rails\
**Created:** [March 24, 2009, 3:57pm UTC](https://www.ruby-forum.com/t/sanitize-within-helpers/163745 "2009-03-24T15:57:17Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Michael\_Ragalie](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/e9c0ed/32.png) [@Michael\_Ragalie](https://www.ruby-forum.com/u/Michael_Ragalie)\
**Post date:** [March 24, 2009, 3:57pm UTC](https://www.ruby-forum.com/t/sanitize-within-helpers/163745/1 "2009-03-24T15:57:17Z")

</div>

Hello,  
I used to be able to call sanitize (or h) in helpers. When I updated to  
2.3.2 it seems like I am no longer able to access helper methods within  
other helpers. Any tips on how I might be able to get this working  
again?

Thanks,  
-Mike

---

<div class="post-metadata">

**Author:** ![Michael\_Ragalie](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/e9c0ed/32.png) [@Michael\_Ragalie](https://www.ruby-forum.com/u/Michael_Ragalie)\
**Post date:** [March 25, 2009, 3:56pm UTC](https://www.ruby-forum.com/t/sanitize-within-helpers/163745/2 "2009-03-25T15:56:44Z")

</div>

You should be able to call something like:

clean\_html = HTML::Sanitizer.new.sanitize(dirty\_html)

On Tue, Mar 24, 2009 at 3:35 PM, Michael Ragalie \<
