How do you write fractions in mvc3?!?
I know in php its ½
I tried that and it didn’t work.
General gist of what I am doing is just a simple site to list my movie collections, and one movie is titled The Lion King 1 1/2 while another one is Alien 2 which I also want to render as ² in mvc3 but it doesn’t handle these.
I am also making this site with WebMatrix.
Code:
@{
var mId = UrlData[0].AsInt();
var db = Database.Open("PhotoGallery");
var movie = db.QuerySingle(@"SELECT * FROM Movies WHERE Id = @0", mId);
}
<h2 class="title">@movie.Title (@movie.Year)</h2>
Output:
The Lion King 1½
How are you trying to write them out? If using @Model.Field try @Html.Raw(Model.Field) instead.
I wound recommend using the antixss libraries sanitizer first though before storing that data in the database to remove potentially malicious javasrcript