hi you can try doing this
link_to image_tag("Search.png", border: 0), {action: 'search', controller: 'pages'}, {class: 'dock-item'}
or even
link_to image_tag("Search.png", border: 0), {action: 'search', controller: 'pages'}, class: 'dock-item'
note that the position of the curly braces is very important, because if you miss them out, rails will assume they form a single hash parameters (read more about this here)
and according to the api for link_to:
link_to(name, options = {}, html_options = nil)
- the first parameter is the string to be shown (or it can be an image_tag as well)
- the second is the parameter for the url of the link
- the last item is the optional parameter for declaring the html tag, e.g. class, onchange, etc.
hope it helps! =)