Upon retrieving a rating (which can be more than 5) from the database, I aim to dynamically generate glyphicon stars based on the received value when the page loads. The code snippet below demonstrates how the value is retrieved:
int rating_count = DBinteract.get_rating_count(ticket_id);
Although I attempted to iterate through and append the glyphicons to a div based on the retrieved value, only one star appears upon initial page load.
for (int i = 0; i < rating_count; i++)
{
this.rating_count.InnerHtml="<span class='glyphicon glyphicon-star'></span>";
}
Here's the div where I intend to display the stars:
<td>
<div id="rating_count" runat="server"></div>
</td>