<%@ taglib uri="/WEB-INF/jspwiki.tld" prefix="wiki" %> <%@ page import="org.apache.wiki.*" %> <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %> <%@ page import="javax.servlet.jsp.jstl.fmt.*" %><%--CHECK why is this needed --%> <% WikiContext c = WikiContext.findContext( pageContext ); WikiPage p = c.getPage(); String pagename = p.getName(); /* check possible permalink (blogentry) pages */ String blogcommentpage=""; String mainblogpage=""; if( pagename.indexOf("_blogentry_") != -1 ) { blogcommentpage = TextUtil.replaceString( pagename, "blogentry", "comments" ); mainblogpage = pagename.substring(0, pagename.indexOf("_blogentry_")); } %> <%-- If the page is an older version, then offer a note and a possibility to restore this version as the latest one. --%>
<%----%>
  
<%-- Inserts no text if there is no page. --%> <%-- Inserts blogcomment if appropriate <% if( !blogpage.equals("") ) { %> --%> <% if( ! mainblogpage.equals("") ) { %> <% if( ! blogcommentpage.equals("") ) { %>
<% }; %>
   
<% }; %> <%-- FIXME: Should also note when a wrong version has been fetched. --%>