Mixing a call to .rhtml AND .rjs


I’ll admit that I’m being lazy and trying to avoid learning enough
javascript to implement this in Script.aculo.us, but if I have to I

If I don’t then someone will have answered this question I have. :wink:

I have an .rhtml being rendered but I want to also ‘flash’ a

element on the screen that matches a criteria, this page is NOT being
updated via ajax.

Any clue?


I’m not sure I have enough information about what you are trying to do,
but do you mean that you want to put flash data into a div if certain
criteria is true at the time the page is rendered? If so, you could just
do this in your .rhtml file:

<% if condition -%>

<%= flash[:error] -%>
<% end -%> ...

If you are wanting to do something after the page is rendered based on
user interaction, that would need to be done w/ javascript.


Jean N. wrote:

updated via ajax.

Any clue?



William P.

I think what you want to do is this:

Watch me highlight!