Forum: Ruby on Rails rails image link with javascript ...

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Mufaddal K. (Guest)
on 2006-01-14 01:34
(Received via mailing list)
Is there a rails rhtml / tag to do something like this:

<a href='/search_action'><img src='/images/button-on.gif' border='0'

Any ideas?

Derrick S. (Guest)
on 2006-01-14 01:49
(Received via mailing list)
Are the images necessary for this rollover?  Have you considered
using CSS to achieve this effect?

Mufaddal K. (Guest)
on 2006-01-14 02:01
(Received via mailing list)
Unfortunately, yes .. require the rollovers using the images.
Any ideas?
Mufaddal K. (Guest)
on 2006-01-14 02:35
(Received via mailing list)
I have 2 layouts xyz.rhtml and abc.rhtml. I have some common code in

I want to render common.rhtml in both xyz.rhtml and abc.rhtml.

Que 1. What is the best way in ror to do this?

Should I do the following in xyz.rhtml and abc.rhtml:
            <%= render(:file => "common.rhtml", :use_full_path =>

Que 2. If answer to above question is yes, then is my usage is correct?
(Note: All three files are in app/views/layouts)

Currently when I do the above I get the following error:

  ActionView::ActionViewError in Tracking#search_order

Showing /app/views/layouts/xyz.rhtml/ where line *#20* raised:

|No rhtml, rxml, or delegate template found for common.rhtml|

Extracted source (around line *#20*):

|17: 			</div>
18: 		</div>
19: 		<div>
20: 			<%= render(:file => "common.rhtml")%>
21: 		</div>

James E. (Guest)
on 2006-01-14 03:02
(Received via mailing list)
On 1/13/06, Mufaddal K. <removed_email_address@domain.invalid> wrote:
>        </div>
> Thanks,

You might also try render_partial('/common'), where common.rhtml is
moved to app/views/_common.rhtml

This topic is locked and can not be replied to.