中文介绍
Razor4Orchard v1.2介绍

Project Description
Display Razor view in Orchard.


Orchard (http://orchard.codeplex.com)
RazorEngine (http://razorengine.codeplex.com)

Sample:

@{
 var userid = 0;
 var username = string.Empty;
 if(Model.Services.WorkContext.CurrentUser != null)
 {
  userid = Model.Services.WorkContext.CurrentUser.Id;
  username = Model.Services.WorkContext.CurrentUser.UserName;
 }
}
Hello <a href="/OrchardLocal/Admin/Users/Edit/@userid">@username</a>

Last edited Feb 10, 2012 at 2:44 PM by zhong_zhaofeng, version 5