<%@ Page Language="C#" Inherits="System.Web.Mvc.ViewPage" MasterPageFile="~/Models/App.master"%> <% Title = Model.Title+" (édition) - "+ViewData["BlogTitle"]; %>

<%= Html.ActionLink(Model.Title,"UserPost",new{user=Model.UserName,title=Model.Title}) %> (édition) - <%=ViewData["BlogTitle"]%> <%= YavscHelpers.SiteName %>

(Id:<%=Model.Id%>, <%= Model.Posted.ToString("yyyy/MM/dd") %> - <%= Model.Modified.ToString("yyyy/MM/dd") %> <%= Model.Visible? "":", Invisible!" %>) <% if (Membership.GetUser()!=null) if (Membership.GetUser().UserName==Model.UserName) { %> <%= Html.ActionLink("Editer","Edit", new { user=Model.UserName, title = Model.Title }, new { @class="actionlink" }) %> <%= Html.ActionLink("Supprimer","RemovePost", new { user=Model.UserName, title = Model.Title }, new { @class="actionlink" } ) %> <% } %>
<% if (Model != null ) if (Model.Content != null ) { BBCodeHelper.Init (); %> <%= Html.ActionLink(Model.Title,"UserPost",new{user=Model.UserName,title=Model.Title}) %>
<%= BBCodeHelper.Parser.ToHtml(Model.Content) %>
<% } %> Usage BBcodes :
<% foreach (string usage in BBCodeHelper.BBTagsUsage) { %>
<%= usage %>
<% } %>
<%= Html.ValidationSummary("Edition du billet") %> <% using(Html.BeginForm("ValidateEdit","Blogs")) { %> <%= Html.LabelFor(model => model.Title) %>:
<%= Html.TextBox( "Title" ) %> <%= Html.ValidationMessage("Title", "*") %>
<%= Html.LabelFor(model => model.Content) %>:
<%= Html.TextArea( "Content" , new { @class="editblog", @rows="15" }) %> <%= Html.ValidationMessage("Content", "*") %>
<%= Html.CheckBox( "Visible" ) %> <%= Html.LabelFor(model => model.Visible) %> <%= Html.ValidationMessage("Visible", "*") %>
<%= Html.CheckBox( "Preview" ) %> <%= Html.LabelFor(model => model.Preview) %> <%= Html.ValidationMessage("Preview", "*") %> <%= Html.Hidden("Id") %> <%= Html.Hidden("UserName") %>
<% } %>