# Adding html markup to a blog post content field

**URL:** <https://www.ruby-forum.com/t/adding-html-markup-to-a-blog-post-content-field/188618>\
**Category:** Rails\
**Created:** [May 14, 2010, 8:52pm UTC](https://www.ruby-forum.com/t/adding-html-markup-to-a-blog-post-content-field/188618 "2010-05-14T20:52:01Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Norm](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/f475e1/32.png) [@Norm](https://www.ruby-forum.com/u/Norm)\
**Post date:** [May 14, 2010, 8:52pm UTC](https://www.ruby-forum.com/t/adding-html-markup-to-a-blog-post-content-field/188618/1 "2010-05-14T20:52:01Z")

</div>

Hello all,

I have spent the better part of a day getting my “hello world!”  
application, aka. blog, done. I am so loving Rails. One thing that I  
am stumped on is how to enable html in my post.

I have two fields for a Post, title and content. in the content field  
if I enter a url or enter an anchor tag, the link does not show up as  
a link. I don’t have a need for a WYSWIG editor, as I do not care for  
them, I would much rather enter raw html markup and since it is only  
me who is going to be doing the posting I feel confident that it is  
safe.

Thanks,

Norm

---

<div class="post-metadata">

**Author:** ![Norm](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/f475e1/32.png) [@Norm](https://www.ruby-forum.com/u/Norm)\
**Post date:** [May 14, 2010, 9:43pm UTC](https://www.ruby-forum.com/t/adding-html-markup-to-a-blog-post-content-field/188618/2 "2010-05-14T21:43:32Z")

</div>

On 14 May 2010 00:15, Norm [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> me who is going to be doing the posting I feel confident that it is  
> safe.

Are you using \<%= h @your\_text\_string %\>? If so remove the h as this  
is escaping the html. However think very carefully about this. Don’t  
do it for a real application that others will have access to.

Colin
