Member
73 Points
Mar 13, 2012 12:11 AM|vietquang_dhhv|LINK
Hi all!
I want to make a star rating on my web.
My web is ASP.Net
Please help me. Give me a code if possible.
Thanks so much!
Participant
1485 Points
Mar 13, 2012 05:30 AM|pratik_galoria|LINK
First of all put this jquery raty plugin in your page,
then, create one generic handler in your project and put this code,
public class rating : IHttpHandler { public void ProcessRequest (HttpContext context) { // Do whatever you want here with your rated score, which you can get using context.Request.QueryString["score"] context.Response.Write("rated."); //don't forget this line. } public bool IsReusable { get { return false; } } }
edit your jquery raty code with this to call this handler by ajax postback,
$(document).ready(function() { $('.rating').raty({ click: function(score, evt) { jQuery.ajax({ type: "GET", url: "handlers/rating.ashx", data: "score=" + score }); } }); });
Mar 13, 2012 01:44 PM|shalabhk|LINK
hey may be this will help u out. Check it..
All-Star
118593 Points
Mar 15, 2012 01:18 AM|Decker Dong - MSFT|LINK
vietquang_dhhv
I want to make a star rating on my web.
My web is ASP.Net
Please help me. Give me a code if possible.
For Star Rating，I strongly you using Rate Control，and this is an AJAX-based control。You have to download the control from Microsoft website and then use it。
Sample looks like this：
3 replies
Last post Mar 15, 2012 01:18 AM by Decker Dong - MSFT