diff --git a/htroot/Blog.html b/htroot/Blog.html index 4a5b4fe50..59c40370e 100644 --- a/htroot/Blog.html +++ b/htroot/Blog.html @@ -6,7 +6,13 @@ - #%env/templates/header.template%# + #(display)# + #%env/templates/simpleheader.template%# + :: + #%env/templates/header.template%# + :: + #%env/templates/embeddedheader.template%# + #(/display)# #(mode)# #{entries}# diff --git a/htroot/Blog.java b/htroot/Blog.java index f62c3b078..74474b5e0 100644 --- a/htroot/Blog.java +++ b/htroot/Blog.java @@ -82,7 +82,11 @@ public class Blog { final serverObjects prop = new serverObjects(); blogBoard.entry page = null; - boolean hasRights = switchboard.verifyAuthentication(header, true); + final boolean authenticated = switchboard.adminAuthenticated(header) >= 2; + final int display = ((post == null) || (!authenticated)) ? 0 : post.getInt("display", 0); + prop.put("display", display); + + boolean hasRights = switchboard.verifyAuthentication(header, true); final boolean xml = ((String)header.get(httpHeader.CONNECTION_PROP_PATH)).endsWith(".xml"); final String address = yacyCore.seedDB.mySeed.getPublicAddress(); diff --git a/htroot/News.html b/htroot/News.html index 170b4d114..58d94a024 100644 --- a/htroot/News.html +++ b/htroot/News.html @@ -15,7 +15,7 @@ #%env/templates/header.template%#