$(document).ready(function { $('#rate_p<~PostId~>').rating('rate.php?pid=<~PostId~>', {maxvalue:5, curvalue:<~PostRate~>}); });