|
|
@@ -14,7 +14,6 @@
|
|
|
{
|
|
|
<p class="text-red text-center size20">↓↓↓以下是文章加密部分↓↓↓</p>
|
|
|
@Html.Raw(await Model.ProtectContent.ReplaceImgAttribute(Model.Title))
|
|
|
-
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
@@ -57,6 +56,29 @@
|
|
|
}
|
|
|
</div>
|
|
|
}
|
|
|
+@if (!string.IsNullOrEmpty(Model.ProtectContent)&&Model.ProtectContentMode==ProtectContentMode.Password)
|
|
|
+{
|
|
|
+ <div class="row protected-content">
|
|
|
+ @if (Context.Request.Query["password"]!=Model.ProtectPassword)
|
|
|
+ {
|
|
|
+ <p class="text-red text-center size24 margin-bot10">此处内容需要密码可见:</p>
|
|
|
+ <form method="get" enctype="multipart/form-data" class="form-inline">
|
|
|
+ <div class="input-group">
|
|
|
+ <span class="input-group-addon">密码:</span>
|
|
|
+ <input class="form-control" type="text" name="password">
|
|
|
+ <input type="hidden" name="t" value="@SnowFlake.NewId">
|
|
|
+ <span class="input-group-btn">
|
|
|
+ <button class="btn btn-info" type="submit">确定</button>
|
|
|
+ </span>
|
|
|
+ </div>
|
|
|
+ </form>
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ @Html.Raw(await Model.ProtectContent.ReplaceImgAttribute(Model.Title))
|
|
|
+ }
|
|
|
+ </div>
|
|
|
+}
|
|
|
@if(Model.ProtectContentMode==ProtectContentMode.Regions) {
|
|
|
if (Model.ProtectContentLimitMode==RegionLimitMode.AllowRegion&&Regex.IsMatch(Context.Request.Location(),Model.ProtectContentRegions)) {
|
|
|
@Html.Raw(await Model.ProtectContent.ReplaceImgAttribute(Model.Title))
|