On Mon, Jul 27, 2009 at 1:53 PM, Mark Preston<[email protected]> wrote: > ... what I am trying to do is take the value from > > <td><%=h number.m1 %></td> and do this: > > <td> ref to td above X 25</td> > > I don't know how to reference the results from the first td in order to > do the math I want to in a different td. > > I hope I made a little more sense.
Not really. You're not doing *anything* "in a td" -- you're generating markup in a view (unless you're trying to describe using JavaScript to interactively set this value in the client). number.m1 is the same no matter where you refer to it in any given page, so what was already suggested is exactly right: <td><%=h number.m1 %></td> <td><%=h number.m1 * 25 %></td> If that's not the answer, please try to explain what you want to do a little more clearly. -- Hassan Schroeder ------------------------ [email protected] twitter: @hassan --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

