To: "fhmsha@163.com" <fhmsha@163.com>
Date: Sun, 29 Jul 2007 02:55:15 +0800 (CST)
Subject: Re: Bug in Toolkit's rating control
writer.AddAttribute("href", "#");
writer.AddAttribute("onclick", "return false;");
writer.AddAttribute("style", "text-decoration:none");
i have no time to deal with that yet,but i can give you something:
in the link;http://www.youtube.com/watch?v=rp2hQd7mRS0
the Code of Rating is:<a href="#" onclick="ratingComponent.setStars(1); return false;" onmouseover="ratingComponent.showStars(1);" onmouseout="ratingComponent.clearStars();"><img src="/img/icn_star_empty_19x20.gif" id="star__1" class="rating" style="border: 0px"></a>
and in ASP.NET AJAX's Rating, http://asp.net/AJAX/Control-Toolkit/Live/Rating/Rating.aspx
the Code of Rating is:<a href="#" id="ctl00_SampleContent_ThaiRating_A" title="2" style="text-decoration:none"><span id="ctl00_SampleContent_ThaiRating_Star_1" class="ratingStar filledRatingStar" style="float:left;"> </span><span id="ctl00_SampleContent_ThaiRating_Star_2" class="ratingStar filledRatingStar" style="float:left;"> </span><span id="ctl00_SampleContent_ThaiRating_Star_3" class="ratingStar emptyRatingStar" style="float:left;"> </span><span id="ctl00_SampleContent_ThaiRating_Star_4" class="ratingStar emptyRatingStar" style="float:left;"> </span><span id="ctl00_SampleContent_ThaiRating_Star_5" class="ratingStar emptyRatingStar" style="float:left;"> </span></a>
you can compare these codes and you will find that:the ASP.NET AJAX's code miss the "return false;" in "onclick" event.
so you can modify the source code of ASP.NET AJAX,or just wait...if i have good news i will tell you.
hope it can help you
thanks
fhmsha
From: mpj.vervoort
To: fhmsha@163.com
Date: Sat, 28 Jul 2007 03:31:06 +0800 (CST)
Subject: [博客园留言通知]Bug in Toolkit's rating control(来自Marco Vervoort)
Hi,
I saw you wrote on Scot's blog a reply with:
there is something NOT good for UI with Rating Control.
the control of this release add a tag "<a href=#></a>".
when i click the star to rate,if i stay in the bottom of the page,the page will go to the top.i think it is realy bad.
I'm having the same problem. Do you perhaps have a solution to the problem? I'm planning to implement it on my personal self written blog: www.kobuz.net (sorry its in Dutch)
Regards,
Marco Vervoort
发送者:Marco Vervoort
Email:mpj.vervoort
发送时间:2007-07-28 03:31
消息来自: http://www.cnblogs.com/fhmsha/