<%@ page import="javax.servlet.*" import="javax.servlet.http.*" import="java.io.*" import="java.util.*" import="org.apache.nutch.searcher.*" import="org.apache.nutch.parse.ParseText" %><% // show the content of a hit as plain text NutchBean bean = NutchBean.get(application); bean.LOG.info("text request from " + request.getRemoteAddr()); Hit hit = new Hit(Integer.parseInt(request.getParameter("idx")), Integer.parseInt(request.getParameter("id"))); HitDetails details = bean.getDetails(hit); String text = bean.getParseText(details).getText(); if (text.trim().equals("")) text = null; // 20041005, xing // This "CharEncodingForConversion" thing is only pertinent to // html parser (plugin parse-html) in current nutch. None of // other parser plugins are into it. So we worry it later. %>"> <% out.flush(); %> <%@ taglib uri="http://jakarta.apache.org/taglibs/i18n" prefix="i18n" %>

"/>
<% if (text != null) {%>
<%= text %>
<% } else { %> <% } %>