lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Hatcher <e...@ehatchersolutions.com>
Subject Re: I can't make index for .jsp files with IndexHtml!
Date Sun, 05 Dec 2004 08:12:37 GMT
On Dec 5, 2004, at 1:36 AM, Benson Fang wrote:
> I got a problem: Everytime I try to make an index with IndexHtml for a
> directory under Tomcat webapps which includes .html and .jsp files, it
> only scans for .html files, but not .jsp files. However, it works
> while I make index with IndexFiles.

IndexHTML has this in its source code:

if (file.getPath().endsWith(".html") || // index .html files
	       file.getPath().endsWith(".htm") || // index .htm files
	       file.getPath().endsWith(".txt"))...

This is why .jsp files are excluded.

Keep in mind that JSP files are not pure HTML (not even close in most 
cases, especially when using JSF).  I'm not sure what the built-in HTML 
parser will do with .jsp files.  Generally content shouldn't be in the 
view layer, so indexing .jsp pages may or may not be useful.  May I 
suggest switching to a Java web development framework that uses pure 
HTML templates?  Tapestry - http://jakarta.apache.org/tapestry :)

	Erik


---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-user-help@jakarta.apache.org


Mime
View raw message