# Documentation for html\_options = {}

**URL:** <https://www.ruby-forum.com/t/documentation-for-html-options/72119>\
**Category:** Rails\
**Created:** [October 14, 2006, 2:36pm UTC](https://www.ruby-forum.com/t/documentation-for-html-options/72119 "2006-10-14T14:36:20Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![lee](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/l/bc8723/32.png) [@lee](https://www.ruby-forum.com/u/lee)\
**Post date:** [October 14, 2006, 2:36pm UTC](https://www.ruby-forum.com/t/documentation-for-html-options/72119/1 "2006-10-14T14:36:20Z")

</div>

Hi, trying to locate documentation for html\_options = {} as allowed in  
RJS calls such as link\_to\_remote.

Can anyone point me in the right direction please?

---

<div class="post-metadata">

**Author:** ![lee](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/l/bc8723/32.png) [@lee](https://www.ruby-forum.com/u/lee)\
**Post date:** [October 14, 2006, 11:25pm UTC](https://www.ruby-forum.com/t/documentation-for-html-options/72119/2 "2006-10-14T23:25:02Z")

</div>

html\_options is simply a hash that gets directly translated into HTML  
attributes.

Example:

\<%= img\_tag ‘url’, :html\_options =\> {:width =\> 1, :height =\> 2, :my\_attr  
=\>  
‘ohnoes’} %\>

becomes:

![]()

Jason

---

<div class="post-metadata">

**Author:** ![lee](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/l/bc8723/32.png) [@lee](https://www.ruby-forum.com/u/lee)\
**Post date:** [October 14, 2006, 11:27pm UTC](https://www.ruby-forum.com/t/documentation-for-html-options/72119/3 "2006-10-14T23:27:02Z")

</div>

Sorry, didn’t mean to have the :html\_options in there, should read as:

\<%= img\_tag ‘url’, :width =\> 1, :height =\> 2, :my\_attr =\> ‘ohnoes’ %\>

Jason
