Very often i write code like:
<img class="hasMenu" src="<%= (Model.Image==null)?Url.Content("~/Content/NoImage.jpg"):Model.Image.standard %>"
alt="Main image" />
Is there any predefined function which could beauty this code?
Something like: ValueOrDefault(Model.Image.standard,Url.Content("~/Content/NoImage.jpg"))