Vamos a ver quedaria mas o menos asi:
Código html:
Ver original<form name="test" action="" method="post"> <input type="hidden" id="input-rating" name="input-rating" value="<%= params[:input-rating] %>" />
<div id="rater" class="rater">
<input name="submit" type="submit" value="Votar" />
<%= "Value is: #{params[:input-rating]}" if params[:input-rating] %>
<script language="javascript"> var pValue = '<%= params[:input-rating] %>';
var r = new rating('stars', 5, pValue || 0 , true, 'input-rating');
Saludos