Razor Syntax with mixed markup
asp.net-mvc, asp.net-mvc-5.1, c#, razor
Solution
You can always use the `@` character with an argument as well. This is actually my preferred method when mixing razor in.
<img src="/path/path/@(Model.PhotoId).jpg"/>
Problem
MVC 5.1 I have the id of a photo in my Model. Model.PhotoId When I try to mix it into the HTML, there is a failed error message ``` <img src="/path/path/@Model.PhotoId.jpg"/> ``` Now do I tell Razor that the PhotoId has ended and the ".jpg" has begun?